-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Update: Slack: Adding more info to Slack Open Channel command #13343
base: main
Are you sure you want to change the base?
Conversation
Thank you for your contribution! 🎉 🔔 @momme-rtf @Elliot67 @jfkisafk @thomaslombart you might want to have a look. You can use this guide to learn how to check out the Pull Request locally in order to test it. We're currently experiencing high demand and limited capacity. As a result, extension reviews might take longer than usual to get the initial review. Please expect an initial review within 5-10 business days. |
…aycast-extensions into feature/slack-search-update
Hi @RobErskine |
Hi @momme-rtf, thanks for your thoughts. I can see your point about keeping it uncluttered. Personally my org on Slack is over 700 people all over the world, so looking people up and understanding where they are and what time it is for them is crazy useful for me. I do like your suggestion of adding in a Preference for this though to keep this simple for folks that like the way it is currently. I was already thinking in the shower that I should probably add in a preference for how the time should be displayed (am/pm or 24 hour). How about this:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM other than the broader conversation we are having around preferences.
👋🏼 hey @jfkisafk @momme-rtf, I went ahead and added two additional preferences to the extension for Time Format as well as Displaying Additional Metadata in the Search Command: I also added in HH:MM to the Slack Status Tooltip so if someone is grabbing lunch, or at a doctor's appt on the same day, the return time will be displayed. This screenshot also has the "Show Extra Metadata" option turned off (which is the default). Here is what it looks like with the extra metadata turned on, as well as the 24 hour time format. Let me know if you have any other feedback! |
Awesome @RobErskine |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comments but lgtm 🚀
Co-authored-by: stelo <42366677+jfkisafk@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor suggested changes for type casting the preferences from raycast-env.d.ts, but not required. Ty for this awsum addition 🫶
extensions/slack/src/search.tsx
Outdated
|
||
const { displayExtraMetadata } = getPreferenceValues<Preferences>(); | ||
const { displayExtraMetadata } = getPreferenceValues(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const { displayExtraMetadata } = getPreferenceValues(); | |
const { displayExtraMetadata } = getPreferenceValues<Preferences.Search>(); |
extensions/slack/src/shared/utils.ts
Outdated
|
||
function getTimeLocale(): string { | ||
const timeFormat = getPreferenceValues<Preferences>().timeFormat; | ||
const timeFormat = getPreferenceValues().timeFormat; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const timeFormat = getPreferenceValues().timeFormat; | |
const timeFormat = getPreferenceValues<Preferences>().timeFormat; |
Please rebase on top of #13039 and see if everything works as before? This will add a new command and the previous |
…aycast-extensions into feature/slack-search-update # Conflicts: # extensions/slack/CHANGELOG.md # extensions/slack/package.json # extensions/slack/src/search.tsx # extensions/slack/src/shared/client/SlackClient.ts # extensions/slack/src/shared/utils.ts # extensions/slack/src/unread-messages.tsx
👋🏼 hi there. This is pretty poor (or good?) timing on my end but I was working on an update to the This PR adds Metadata to the Open Channel command to show Slack member's job title, current status, timezone, as well as their current time. Also added in the option to display time in AM/PM or 24 hour time. With the Metadata set to |
Hey Rob, I'll review the PR next week 🙂 |
It seems other extension changes have slipped in while merging/rebasing. Could you fix it before I review your PR? 🙂 |
@thomaslombart sorry about that; not sure how that happened while I was rebasing. I have merged |
Description
Hi there! I updated the Slack Search Command to pull more data from Slack, like the user's Title (if it exists), their current status in Slack, when they will be back, their timezone location, as well as their current local time.
Current Search Command UI
New Search Command UI
Screencast
Code-search.tsx.slack_2024-07-05.at.16.49.mp4
Bonus
Adds Emojify to Unread Messages as well to help make messages with emojis more readable:
Checklist
npm run build
and tested this distribution build in Raycastassets
folder are used by the extension itselfREADME
are placed outside of themetadata
folder