Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: introduce new categories field for UI Action Buttons #33066

Merged
merged 31 commits into from
Oct 10, 2024

Conversation

Dnouv
Copy link
Member

@Dnouv Dnouv commented Aug 15, 2024

Proposed changes (including videos or screenshots)

  • Adds a new button in the message hover toolbar; the button has an icon ✨ where the Apps can register the actions. Any App that mentions the category: AI on the App buttons, those buttons will be rendered on this new context.

Issue(s)

Steps to test or reproduce

Further comments

Copy link

changeset-bot bot commented Aug 15, 2024

🦋 Changeset detected

Latest commit: d587947

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 37 packages
Name Type
@rocket.chat/ui-kit Minor
@rocket.chat/i18n Minor
@rocket.chat/meteor Minor
@rocket.chat/apps-engine Major
@rocket.chat/core-services Patch
@rocket.chat/core-typings Minor
@rocket.chat/fuselage-ui-kit Major
@rocket.chat/livechat Patch
@rocket.chat/rest-typings Minor
rocketchat-services Patch
@rocket.chat/mock-providers Patch
@rocket.chat/ui-contexts Major
@rocket.chat/web-ui-registration Major
@rocket.chat/apps Patch
@rocket.chat/ddp-streamer Patch
@rocket.chat/presence Patch
@rocket.chat/account-service Patch
@rocket.chat/authorization-service Patch
@rocket.chat/omnichannel-transcript Patch
@rocket.chat/presence-service Patch
@rocket.chat/queue-worker Patch
@rocket.chat/stream-hub-service Patch
@rocket.chat/network-broker Patch
@rocket.chat/omnichannel-services Patch
@rocket.chat/uikit-playground Patch
@rocket.chat/api-client Patch
@rocket.chat/cron Patch
@rocket.chat/ddp-client Patch
@rocket.chat/freeswitch Patch
@rocket.chat/gazzodown Major
@rocket.chat/model-typings Patch
@rocket.chat/license Patch
@rocket.chat/pdf-worker Patch
@rocket.chat/ui-avatar Major
@rocket.chat/ui-video-conf Major
@rocket.chat/models Patch
@rocket.chat/instance-status Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

dionisio-bot bot commented Aug 15, 2024

Looks like this PR is ready to merge! 🎉
If you have any trouble, please check the PR guidelines

Copy link

codecov bot commented Aug 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 58.59%. Comparing base (760ae5c) to head (d587947).
Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop   #33066   +/-   ##
========================================
  Coverage    58.59%   58.59%           
========================================
  Files         2739     2739           
  Lines        65702    65705    +3     
  Branches     14830    14827    -3     
========================================
+ Hits         38497    38500    +3     
  Misses       24425    24425           
  Partials      2780     2780           
Flag Coverage Δ
unit 75.66% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@Dnouv Dnouv added this to the 6.12 milestone Aug 16, 2024
@Dnouv
Copy link
Member Author

Dnouv commented Aug 21, 2024

The CI is failing due to a change introduced on the #33001 for Apps Engine.

Only requires FE review since modifying the packages has introduced those additional required reviews.

Depends on the package update in #33119

@Dnouv Dnouv marked this pull request as ready for review August 22, 2024 07:05
@Dnouv Dnouv requested a review from a team as a code owner August 22, 2024 07:05
@rodrigok rodrigok modified the milestones: 6.12, 6.13 Aug 22, 2024
Copy link
Contributor

@rique223 rique223 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't necessary, but you might consider subdividing the useMessageToolbarStarsAppsAction logic into two functions like this:

const filterActions = useCallback((actions) => { ...filtering logic... }, [{dependencies}]);

const mapActions = useCallback((actions) => { ...mapping logic... }, [{dependencies}]);

Then, you can use them like this:
const data = useMemo( () => mapActions(filterActions(queryResult.data)), [{dependencies}] );
This approach better adheres to functional programming best practices, improves readability, and makes future code extensions/refactors easier. However, if this suggestion isn't in the scope of the PR, feel free to disregard it.

apps/meteor/client/hooks/useAppActionButtons.ts Outdated Show resolved Hide resolved
apps/meteor/client/hooks/useAppActionButtons.ts Outdated Show resolved Hide resolved
packages/i18n/src/locales/en.i18n.json Outdated Show resolved Hide resolved
@Dnouv Dnouv requested a review from rique223 August 23, 2024 02:06
rique223
rique223 previously approved these changes Aug 23, 2024
@Dnouv Dnouv added the stat: QA assured Means it has been tested and approved by a company insider label Aug 23, 2024
@dionisio-bot dionisio-bot bot added the stat: ready to merge PR tested and approved waiting for merge label Aug 23, 2024
@dionisio-bot dionisio-bot bot removed the stat: ready to merge PR tested and approved waiting for merge label Sep 9, 2024
@Dnouv Dnouv requested review from a team as code owners September 27, 2024 15:16
@Dnouv Dnouv changed the title feat: new UI kit context for apps feat: introduce new categories field for UI Action Buttons Oct 1, 2024
@Dnouv Dnouv requested a review from d-gubert October 9, 2024 07:56
@Dnouv Dnouv added the stat: QA assured Means it has been tested and approved by a company insider label Oct 10, 2024
@dionisio-bot dionisio-bot bot added the stat: ready to merge PR tested and approved waiting for merge label Oct 10, 2024
@kodiakhq kodiakhq bot merged commit debd3ff into develop Oct 10, 2024
49 checks passed
@kodiakhq kodiakhq bot deleted the new/app_ui_menu branch October 10, 2024 09:00
@ggazzo ggazzo modified the milestones: 6.14, 7.0 Oct 17, 2024
This was referenced Oct 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stat: QA assured Means it has been tested and approved by a company insider stat: ready to merge PR tested and approved waiting for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants