@fibery/ui-kit 4.2.0 → 4.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/package.json +9 -11
- package/src/antd/input-number.tsx +4 -4
- package/src/antd/input.tsx +1 -1
- package/src/apca.lc-low.test.ts +1 -3
- package/src/apca.test.ts +42 -43
- package/src/apca.ts +38 -39
- package/src/app-icon-with-fallback.tsx +6 -2
- package/src/avatar-colors.ts +71 -0
- package/src/avatar.tsx +2 -10
- package/src/banner/banner.tsx +1 -2
- package/src/box.tsx +26 -16
- package/src/button/back-button.tsx +2 -2
- package/src/button/make-button-colors.ts +13 -13
- package/src/button/select-button.tsx +2 -2
- package/src/canvas-colors.ts +71 -118
- package/src/checkbox.tsx +3 -3
- package/src/collapsible-section.tsx +3 -3
- package/src/color-filter.test.ts +13 -0
- package/src/color-filter.ts +26 -3
- package/src/color-utils.ts +9 -2
- package/src/command-menu/nested-command-menu.tsx +2 -2
- package/src/date-picker/date-range-picker-popup-content.tsx +3 -2
- package/src/date-picker/date-range-picker.tsx +23 -1
- package/src/date-picker/relative-date-picker.tsx +3 -2
- package/src/date-picker/single-date-picker-popup-content.tsx +3 -2
- package/src/date-picker/single-date-picker.tsx +19 -2
- package/src/design-system/alpha-coefficients.ts +235 -0
- package/src/design-system/alpha.ts +10 -1
- package/src/design-system/colors-enum.dark.neutral.test.ts +168 -168
- package/src/design-system/colors-enum.dark.warm.test.ts +168 -168
- package/src/design-system/colors-enum.light.neutral.test.ts +168 -168
- package/src/design-system/colors-enum.light.warm.test.ts +168 -168
- package/src/design-system/colors.ts +231 -154
- package/src/design-system/fns.avatarPlaceholder.dark.neutral.test.ts +52 -0
- package/src/design-system/fns.avatarPlaceholder.dark.warm.test.ts +52 -0
- package/src/design-system/fns.avatarPlaceholder.light.neutral.test.ts +52 -0
- package/src/design-system/fns.avatarPlaceholder.light.warm.test.ts +52 -0
- package/src/design-system/fns.enum.ts +2 -0
- package/src/design-system/fns.icon.ts +1 -1
- package/src/design-system/fns.ts +43 -13
- package/src/design-system/theme.test.ts +4 -6
- package/src/design-system/theme.ts +22 -13
- package/src/design-system/vars.test.ts +2 -2
- package/src/design-system/vars.ts +3 -3
- package/src/design-system.ts +3 -1
- package/src/dot.tsx +1 -0
- package/src/double-apply.ts +2 -2
- package/src/emoji-picker/primitives/footer.tsx +1 -1
- package/src/emoji-picker/utils/frequently.ts +1 -1
- package/src/favorites-icon.tsx +2 -2
- package/src/fibermoji-placeholder.tsx +23 -56
- package/src/fibery-brand-logo.tsx +82 -0
- package/src/field-container.tsx +2 -2
- package/src/field-type-icon.tsx +18 -18
- package/src/file-item/file-menu-items.tsx +1 -1
- package/src/file-item/file-preview-actions.tsx +1 -1
- package/src/format-date-from-now.ts +10 -5
- package/src/header-layout.tsx +41 -24
- package/src/highlight-colors.test.ts +1 -1
- package/src/highlight-colors.ts +27 -0
- package/src/icons/ast/appearance-auto.ts +1 -1
- package/src/icons/ast/architect.ts +12 -0
- package/src/icons/ast/arrow-back.ts +12 -0
- package/src/icons/ast/arrow-down.ts +12 -0
- package/src/icons/ast/{send-arrow.ts → arrow-send.ts} +3 -3
- package/src/icons/ast/arrow-up.ts +12 -0
- package/src/icons/ast/avatar.ts +12 -0
- package/src/icons/ast/backlog.ts +12 -0
- package/src/icons/ast/{check-circle-filled.ts → circle-check-filled.ts} +3 -3
- package/src/icons/ast/{check-circle.ts → circle-check.ts} +3 -3
- package/src/icons/ast/{error-circle-filled.ts → circle-cross-filled.ts} +3 -3
- package/src/icons/ast/circle-cross.ts +12 -0
- package/src/icons/ast/{info-circle-filled.ts → circle-info-filled.ts} +3 -3
- package/src/icons/ast/{info-circle.ts → circle-info.ts} +3 -3
- package/src/icons/ast/circle-pause.ts +12 -0
- package/src/icons/ast/circle-play.ts +12 -0
- package/src/icons/ast/comments.ts +12 -0
- package/src/icons/ast/credits-filled.ts +1 -1
- package/src/icons/ast/{add-database.ts → database-add.ts} +3 -3
- package/src/icons/ast/database-outline.ts +12 -0
- package/src/icons/ast/eye-off.ts +12 -0
- package/src/icons/ast/favorites-filled.ts +12 -0
- package/src/icons/ast/{switch-to-mention.ts → field-units-large.ts} +3 -3
- package/src/icons/ast/files.ts +12 -0
- package/src/icons/ast/{smart-folder.ts → folder-smart.ts} +3 -3
- package/src/icons/ast/fullscreen-mode-off.ts +12 -0
- package/src/icons/ast/fullscreen-mode-on.ts +1 -1
- package/src/icons/ast/{add-group.ts → group-add.ts} +3 -3
- package/src/icons/ast/{image-xmark.ts → image-error.ts} +3 -3
- package/src/icons/ast/index.tsx +132 -217
- package/src/icons/ast/{add-integration.ts → integration-add.ts} +3 -3
- package/src/icons/ast/integration-discourse.ts +12 -0
- package/src/icons/ast/integration-fibery.ts +12 -0
- package/src/icons/ast/integration-figma.ts +12 -0
- package/src/icons/ast/integration-github.ts +12 -0
- package/src/icons/ast/integration-gitlab.ts +12 -0
- package/src/icons/ast/integration-google-drive.ts +12 -0
- package/src/icons/ast/integration-google-map.ts +12 -0
- package/src/icons/ast/integration-intercom.ts +12 -0
- package/src/icons/ast/integration-jira.ts +12 -0
- package/src/icons/ast/integration-loom.ts +12 -0
- package/src/icons/ast/integration-miro.ts +12 -0
- package/src/icons/ast/integration-mixpanel.ts +12 -0
- package/src/icons/ast/integration-slack.ts +12 -0
- package/src/icons/ast/{suggest-integration.ts → integration-suggest.ts} +3 -3
- package/src/icons/ast/integration-twitter.ts +12 -0
- package/src/icons/ast/integration-unsplash.ts +12 -0
- package/src/icons/ast/integration-youtube.ts +12 -0
- package/src/icons/ast/integration-zendesk.ts +12 -0
- package/src/icons/ast/limits.ts +12 -0
- package/src/icons/ast/lock-filled.ts +12 -0
- package/src/icons/ast/lock.ts +1 -1
- package/src/icons/ast/move-down.ts +12 -0
- package/src/icons/ast/move-up.ts +12 -0
- package/src/icons/ast/open-in-panel.ts +12 -0
- package/src/icons/ast/open-link.ts +12 -0
- package/src/icons/ast/people-all.ts +12 -0
- package/src/icons/ast/people-group-remove.ts +12 -0
- package/src/icons/ast/people-group.ts +12 -0
- package/src/icons/ast/{invite-people.ts → people-invite.ts} +3 -3
- package/src/icons/ast/{remove-people.ts → people-remove.ts} +3 -3
- package/src/icons/ast/people-role.ts +12 -0
- package/src/icons/ast/people-x.ts +12 -0
- package/src/icons/ast/plus.ts +12 -0
- package/src/icons/ast/preferences.ts +12 -0
- package/src/icons/ast/propagate.ts +12 -0
- package/src/icons/ast/{add-reactions.ts → reactions-add.ts} +3 -3
- package/src/icons/ast/redo.ts +12 -0
- package/src/icons/ast/references.ts +12 -0
- package/src/icons/ast/richeditor-block-callout.ts +1 -1
- package/src/icons/ast/richeditor-block-code.ts +1 -1
- package/src/icons/ast/richeditor-block-embed.ts +1 -1
- package/src/icons/ast/richeditor-block-entity.ts +1 -1
- package/src/icons/ast/richeditor-block-file.ts +1 -1
- package/src/icons/ast/richeditor-block-h1.ts +1 -1
- package/src/icons/ast/richeditor-block-h2.ts +1 -1
- package/src/icons/ast/richeditor-block-h3.ts +1 -1
- package/src/icons/ast/richeditor-block-h4.ts +1 -1
- package/src/icons/ast/richeditor-block-mention.ts +1 -1
- package/src/icons/ast/richeditor-block-paragraph.ts +1 -1
- package/src/icons/ast/richeditor-block-quote.ts +1 -1
- package/src/icons/ast/richeditor-checklist-create.ts +1 -1
- package/src/icons/ast/richeditor-image-align-center.ts +1 -1
- package/src/icons/ast/richeditor-image-align-left.ts +1 -1
- package/src/icons/ast/richeditor-image-align-right.ts +1 -1
- package/src/icons/ast/richeditor-image.ts +12 -0
- package/src/icons/ast/richeditor-linkedhighlight-create.ts +1 -1
- package/src/icons/ast/richeditor-list-bullet.ts +1 -1
- package/src/icons/ast/richeditor-list-indent.ts +1 -1
- package/src/icons/ast/richeditor-list-ordered.ts +1 -1
- package/src/icons/ast/richeditor-list-unindent.ts +1 -1
- package/src/icons/ast/richeditor-mark-code.ts +1 -1
- package/src/icons/ast/richeditor-mark-em.ts +1 -1
- package/src/icons/ast/richeditor-mark-highlight.ts +1 -1
- package/src/icons/ast/richeditor-mark-strike.ts +1 -1
- package/src/icons/ast/richeditor-mark-strong.ts +1 -1
- package/src/icons/ast/richeditor-mark-text-background-color.ts +1 -1
- package/src/icons/ast/richeditor-mark-underline.ts +1 -1
- package/src/icons/ast/richeditor-table-create.ts +1 -1
- package/src/icons/ast/richeditor-video-upload.ts +1 -1
- package/src/icons/ast/{bolt.ts → rule.ts} +3 -3
- package/src/icons/ast/simple-compass.ts +1 -1
- package/src/icons/ast/space-add.ts +12 -0
- package/src/icons/ast/{move-space.ts → space-move.ts} +3 -3
- package/src/icons/ast/type-button.ts +1 -1
- package/src/icons/ast/type-checkbox.ts +1 -1
- package/src/icons/ast/type-date.ts +1 -1
- package/src/icons/ast/type-email.ts +1 -1
- package/src/icons/ast/type-emoji.ts +1 -1
- package/src/icons/ast/type-formula.ts +1 -1
- package/src/icons/ast/type-location.ts +1 -1
- package/src/icons/ast/type-lookup.ts +1 -1
- package/src/icons/ast/type-money.ts +1 -1
- package/src/icons/ast/type-multi-select.ts +1 -1
- package/src/icons/ast/type-number.ts +1 -1
- package/src/icons/ast/type-percent.ts +1 -1
- package/src/icons/ast/type-phone.ts +1 -1
- package/src/icons/ast/type-relation.ts +1 -1
- package/src/icons/ast/type-rich-text.ts +1 -1
- package/src/icons/ast/type-single-select.ts +1 -1
- package/src/icons/ast/type-text.ts +1 -1
- package/src/icons/ast/undo.ts +12 -0
- package/src/icons/ast/units-avatar.ts +1 -1
- package/src/icons/ast/units-collection.ts +1 -1
- package/src/icons/ast/units-counter.ts +1 -1
- package/src/icons/ast/units-date.ts +1 -1
- package/src/icons/ast/units-field-icon-button.ts +1 -1
- package/src/icons/ast/units-field.ts +1 -1
- package/src/icons/ast/units-input.ts +1 -1
- package/src/icons/ast/units-normal.ts +12 -0
- package/src/icons/ast/units-progress-bar.ts +1 -1
- package/src/icons/ast/units-rich-text.ts +1 -1
- package/src/icons/ast/units-snippet.ts +1 -1
- package/src/icons/ast/unlock.ts +12 -0
- package/src/icons/ast/{clear-value.ts → value-clear.ts} +3 -3
- package/src/icons/ast/view-app.ts +12 -0
- package/src/icons/ast/workflow.ts +12 -0
- package/src/icons/react/{anthropic.tsx → architect.tsx} +5 -5
- package/src/icons/react/arrow-back.tsx +18 -0
- package/src/icons/react/arrow-down.tsx +18 -0
- package/src/icons/react/arrow-send.tsx +18 -0
- package/src/icons/react/{app-wiki.tsx → arrow-up.tsx} +5 -5
- package/src/icons/react/avatar.tsx +18 -0
- package/src/icons/react/backlog.tsx +18 -0
- package/src/icons/react/circle-check-filled.tsx +18 -0
- package/src/icons/react/{add-database.tsx → circle-check.tsx} +5 -5
- package/src/icons/react/circle-cross-filled.tsx +18 -0
- package/src/icons/react/circle-cross.tsx +18 -0
- package/src/icons/react/circle-info-filled.tsx +18 -0
- package/src/icons/react/circle-info.tsx +18 -0
- package/src/icons/react/circle-pause.tsx +18 -0
- package/src/icons/react/circle-play.tsx +18 -0
- package/src/icons/react/comments.tsx +18 -0
- package/src/icons/react/database-add.tsx +18 -0
- package/src/icons/react/database-outline.tsx +18 -0
- package/src/icons/react/{chat-ai.tsx → eye-off.tsx} +5 -5
- package/src/icons/react/favorites-filled.tsx +18 -0
- package/src/icons/react/field-units-large.tsx +18 -0
- package/src/icons/react/{apple.tsx → files.tsx} +5 -5
- package/src/icons/react/folder-smart.tsx +18 -0
- package/src/icons/react/fullscreen-mode-off.tsx +18 -0
- package/src/icons/react/{app-store.tsx → group-add.tsx} +5 -5
- package/src/icons/react/image-error.tsx +18 -0
- package/src/icons/react/index.tsx +132 -217
- package/src/icons/react/{add-integration.tsx → integration-add.tsx} +5 -5
- package/src/icons/react/integration-discourse.tsx +18 -0
- package/src/icons/react/integration-fibery.tsx +18 -0
- package/src/icons/react/integration-figma.tsx +18 -0
- package/src/icons/react/integration-github.tsx +18 -0
- package/src/icons/react/integration-gitlab.tsx +18 -0
- package/src/icons/react/integration-google-drive.tsx +18 -0
- package/src/icons/react/integration-google-map.tsx +18 -0
- package/src/icons/react/{automations-disabled.tsx → integration-intercom.tsx} +5 -5
- package/src/icons/react/integration-jira.tsx +18 -0
- package/src/icons/react/integration-loom.tsx +18 -0
- package/src/icons/react/integration-miro.tsx +18 -0
- package/src/icons/react/{extension-references.tsx → integration-mixpanel.tsx} +5 -5
- package/src/icons/react/integration-slack.tsx +18 -0
- package/src/icons/react/integration-suggest.tsx +18 -0
- package/src/icons/react/integration-twitter.tsx +18 -0
- package/src/icons/react/integration-unsplash.tsx +18 -0
- package/src/icons/react/integration-youtube.tsx +18 -0
- package/src/icons/react/integration-zendesk.tsx +18 -0
- package/src/icons/react/{notifications.tsx → limits.tsx} +5 -5
- package/src/icons/react/lock-filled.tsx +18 -0
- package/src/icons/react/{add-group.tsx → move-down.tsx} +5 -5
- package/src/icons/react/move-up.tsx +18 -0
- package/src/icons/react/open-in-panel.tsx +18 -0
- package/src/icons/react/{ai-search.tsx → open-link.tsx} +5 -5
- package/src/icons/react/people-all.tsx +18 -0
- package/src/icons/react/people-group-remove.tsx +18 -0
- package/src/icons/react/people-group.tsx +18 -0
- package/src/icons/react/{add-reactions.tsx → people-invite.tsx} +5 -5
- package/src/icons/react/people-remove.tsx +18 -0
- package/src/icons/react/people-role.tsx +18 -0
- package/src/icons/react/people-x.tsx +18 -0
- package/src/icons/react/{chat.tsx → plus.tsx} +5 -5
- package/src/icons/react/preferences.tsx +18 -0
- package/src/icons/react/propagate.tsx +18 -0
- package/src/icons/react/reactions-add.tsx +18 -0
- package/src/icons/react/{csv.tsx → redo.tsx} +5 -5
- package/src/icons/react/references.tsx +18 -0
- package/src/icons/react/richeditor-block-callout.tsx +1 -1
- package/src/icons/react/richeditor-block-code.tsx +1 -1
- package/src/icons/react/richeditor-block-embed.tsx +1 -1
- package/src/icons/react/richeditor-block-entity.tsx +1 -1
- package/src/icons/react/richeditor-block-file.tsx +1 -1
- package/src/icons/react/richeditor-block-h1.tsx +1 -1
- package/src/icons/react/richeditor-block-h2.tsx +1 -1
- package/src/icons/react/richeditor-block-h3.tsx +1 -1
- package/src/icons/react/richeditor-block-h4.tsx +1 -1
- package/src/icons/react/richeditor-block-mention.tsx +1 -1
- package/src/icons/react/richeditor-block-paragraph.tsx +1 -1
- package/src/icons/react/richeditor-block-quote.tsx +1 -1
- package/src/icons/react/richeditor-checklist-create.tsx +1 -1
- package/src/icons/react/richeditor-image-align-center.tsx +1 -1
- package/src/icons/react/richeditor-image-align-left.tsx +1 -1
- package/src/icons/react/richeditor-image-align-right.tsx +1 -1
- package/src/icons/react/richeditor-image.tsx +18 -0
- package/src/icons/react/richeditor-linkedhighlight-create.tsx +1 -1
- package/src/icons/react/richeditor-list-bullet.tsx +1 -1
- package/src/icons/react/richeditor-list-indent.tsx +1 -1
- package/src/icons/react/richeditor-list-ordered.tsx +1 -1
- package/src/icons/react/richeditor-list-unindent.tsx +1 -1
- package/src/icons/react/richeditor-mark-code.tsx +1 -1
- package/src/icons/react/richeditor-mark-em.tsx +1 -1
- package/src/icons/react/richeditor-mark-highlight.tsx +1 -1
- package/src/icons/react/richeditor-mark-strike.tsx +1 -1
- package/src/icons/react/richeditor-mark-strong.tsx +1 -1
- package/src/icons/react/richeditor-mark-text-background-color.tsx +1 -1
- package/src/icons/react/richeditor-mark-underline.tsx +1 -1
- package/src/icons/react/richeditor-table-create.tsx +1 -1
- package/src/icons/react/richeditor-video-upload.tsx +1 -1
- package/src/icons/react/{back.tsx → rule.tsx} +5 -5
- package/src/icons/react/{ai-avatar.tsx → space-add.tsx} +5 -5
- package/src/icons/react/space-move.tsx +18 -0
- package/src/icons/react/type-button.tsx +1 -1
- package/src/icons/react/type-checkbox.tsx +1 -1
- package/src/icons/react/type-date.tsx +1 -1
- package/src/icons/react/type-email.tsx +1 -1
- package/src/icons/react/type-emoji.tsx +1 -1
- package/src/icons/react/type-formula.tsx +1 -1
- package/src/icons/react/type-location.tsx +1 -1
- package/src/icons/react/type-lookup.tsx +1 -1
- package/src/icons/react/type-money.tsx +1 -1
- package/src/icons/react/type-multi-select.tsx +1 -1
- package/src/icons/react/type-number.tsx +1 -1
- package/src/icons/react/type-percent.tsx +1 -1
- package/src/icons/react/type-phone.tsx +1 -1
- package/src/icons/react/type-relation.tsx +1 -1
- package/src/icons/react/type-rich-text.tsx +1 -1
- package/src/icons/react/type-single-select.tsx +1 -1
- package/src/icons/react/type-text.tsx +1 -1
- package/src/icons/react/{bolt.tsx → undo.tsx} +5 -5
- package/src/icons/react/units-avatar.tsx +1 -1
- package/src/icons/react/units-collection.tsx +1 -1
- package/src/icons/react/units-counter.tsx +1 -1
- package/src/icons/react/units-date.tsx +1 -1
- package/src/icons/react/units-field-icon-button.tsx +1 -1
- package/src/icons/react/units-field.tsx +1 -1
- package/src/icons/react/units-input.tsx +1 -1
- package/src/icons/react/units-normal.tsx +18 -0
- package/src/icons/react/units-progress-bar.tsx +1 -1
- package/src/icons/react/units-rich-text.tsx +1 -1
- package/src/icons/react/units-snippet.tsx +1 -1
- package/src/icons/react/unlock.tsx +18 -0
- package/src/icons/react/value-clear.tsx +18 -0
- package/src/icons/react/view-app.tsx +18 -0
- package/src/icons/react/workflow.tsx +18 -0
- package/src/icons/svg/appearance-auto.svg +1 -1
- package/src/icons/svg/{arrow-bottom.svg → arrow-down.svg} +1 -1
- package/src/icons/svg/arrow-forward.svg +1 -1
- package/src/icons/svg/arrow-left.svg +1 -1
- package/src/icons/svg/arrow-right.svg +1 -1
- package/src/icons/svg/{arrow-top.svg → arrow-up.svg} +1 -1
- package/src/icons/svg/asterisk.svg +2 -2
- package/src/icons/svg/{automations-error.svg → circle-cross.svg} +1 -1
- package/src/icons/svg/{automations-not-started.svg → circle-pause.svg} +1 -1
- package/src/icons/svg/{automations-in-progress.svg → circle-play.svg} +1 -1
- package/src/icons/svg/collapse-all-horizontal.svg +1 -1
- package/src/icons/svg/collapse-all.svg +1 -1
- package/src/icons/svg/credits-filled.svg +1 -1
- package/src/icons/svg/entity-create.svg +1 -1
- package/src/icons/svg/expand-all-horizontal.svg +1 -1
- package/src/icons/svg/fullscreen-mode-on.svg +2 -3
- package/src/icons/svg/go-to.svg +1 -1
- package/src/icons/svg/integration-unsplash.svg +3 -0
- package/src/icons/svg/layout-double.svg +1 -1
- package/src/icons/svg/layout-single.svg +1 -1
- package/src/icons/svg/limits.svg +3 -0
- package/src/icons/svg/lock-filled.svg +4 -0
- package/src/icons/svg/lock.svg +5 -4
- package/src/icons/svg/page-regular-mode.svg +3 -3
- package/src/icons/svg/page-wide-mode.svg +3 -3
- package/src/icons/svg/{user-group.svg → people-group.svg} +1 -1
- package/src/icons/svg/{user-role.svg → people-role.svg} +1 -1
- package/src/icons/svg/{richeditor/list/indent.svg → richeditor-list-indent.svg} +1 -1
- package/src/icons/svg/richeditor-mark-code.svg +5 -0
- package/src/icons/svg/richeditor-mark-em.svg +3 -0
- package/src/icons/svg/richeditor-mark-highlight.svg +3 -0
- package/src/icons/svg/richeditor-mark-strike.svg +3 -0
- package/src/icons/svg/richeditor-mark-strong.svg +3 -0
- package/src/icons/svg/simple-compass.svg +2 -2
- package/src/icons/svg/space-app.svg +1 -1
- package/src/icons/svg/space-generate.svg +1 -1
- package/src/icons/svg/space-scratch.svg +1 -1
- package/src/icons/svg/space-template.svg +1 -1
- package/src/icons/svg/value-edit.svg +1 -1
- package/src/icons/svg/view-app.svg +6 -0
- package/src/icons/svg/view-gantt.svg +3 -3
- package/src/icons/svg/warning-triangle-filled.svg +1 -1
- package/src/images-gallery/slide-buttons.tsx +3 -3
- package/src/mobile-drawer.tsx +104 -0
- package/src/number-input/types.ts +1 -1
- package/src/palettes/common.ts +3 -3
- package/src/palettes/diff-colors.test.ts +134 -0
- package/src/palettes/diff-colors.ts +135 -1
- package/src/palettes/inspect.canvas-colors.test.ts +63 -63
- package/src/palettes/inspect.defs.colors.neutral-arch.test.ts +196 -64
- package/src/palettes/inspect.defs.colors.neutral-user.test.ts +196 -64
- package/src/palettes/inspect.defs.colors.warm-arch.test.ts +196 -64
- package/src/palettes/inspect.defs.colors.warm-user.test.ts +196 -64
- package/src/palettes/show-colors.test.ts +3 -3
- package/src/palettes/testkit.test.ts +6 -0
- package/src/palettes/testkit.ts +78 -22
- package/src/phone.ts +27 -0
- package/src/reactions/reaction-picker.tsx +3 -3
- package/src/rich-text-embed-error.tsx +2 -2
- package/src/root-theme-provider.test.tsx +2 -3
- package/src/select/select-in-popover.tsx +41 -25
- package/src/select/util.ts +1 -1
- package/src/thematic.tsx +10 -9
- package/src/theme-provider.test.tsx +18 -18
- package/src/theme-provider.tsx +3 -7
- package/src/theme-settings-core.ts +118 -0
- package/src/theme-settings.ts +2 -117
- package/src/theme-snapshots.test.ts +6 -7
- package/src/theming.build.ts +21 -15
- package/src/theming.generated.css +2162 -2034
- package/src/theming.generated.ts +2701 -2549
- package/src/toast/toast.tsx +1 -1
- package/src/toggle-button/round-toggle-button.tsx +28 -4
- package/src/toggle-button/toggle-button.tsx +69 -23
- package/src/toggle-on-off.tsx +0 -9
- package/src/use-is-phone.tsx +3 -27
- package/vitest.config.ts +1 -0
- package/src/icons/ast/ai-avatar.ts +0 -12
- package/src/icons/ast/ai-search.ts +0 -12
- package/src/icons/ast/anthropic.ts +0 -12
- package/src/icons/ast/app-details.ts +0 -12
- package/src/icons/ast/app-store-one-color.ts +0 -12
- package/src/icons/ast/app-store.ts +0 -12
- package/src/icons/ast/app-templates.ts +0 -12
- package/src/icons/ast/app-webhooks.ts +0 -12
- package/src/icons/ast/app-wiki.ts +0 -12
- package/src/icons/ast/apple.ts +0 -12
- package/src/icons/ast/arrow-bottom.ts +0 -12
- package/src/icons/ast/arrow-top.ts +0 -12
- package/src/icons/ast/automations-cancelled.ts +0 -12
- package/src/icons/ast/automations-disabled.ts +0 -12
- package/src/icons/ast/automations-error.ts +0 -12
- package/src/icons/ast/automations-in-progress.ts +0 -12
- package/src/icons/ast/automations-not-started.ts +0 -12
- package/src/icons/ast/automations-success.ts +0 -12
- package/src/icons/ast/back.ts +0 -12
- package/src/icons/ast/backlog-icon.ts +0 -12
- package/src/icons/ast/batch-actions-icon.ts +0 -12
- package/src/icons/ast/bell-filled.ts +0 -12
- package/src/icons/ast/chat-ai.ts +0 -12
- package/src/icons/ast/chat.ts +0 -12
- package/src/icons/ast/clean.ts +0 -12
- package/src/icons/ast/color-coding-filled.ts +0 -12
- package/src/icons/ast/create.ts +0 -12
- package/src/icons/ast/cross-circle.ts +0 -12
- package/src/icons/ast/csv.ts +0 -12
- package/src/icons/ast/database-off.ts +0 -12
- package/src/icons/ast/database-stroke.ts +0 -12
- package/src/icons/ast/demo.ts +0 -12
- package/src/icons/ast/dependency.ts +0 -12
- package/src/icons/ast/dividers.ts +0 -12
- package/src/icons/ast/document.ts +0 -12
- package/src/icons/ast/double-arrow-left.ts +0 -12
- package/src/icons/ast/double-arrow-right.ts +0 -12
- package/src/icons/ast/double-line.ts +0 -12
- package/src/icons/ast/drag-block-handle-single.ts +0 -12
- package/src/icons/ast/edit-value.ts +0 -12
- package/src/icons/ast/extension-assignments.ts +0 -12
- package/src/icons/ast/extension-avatar.ts +0 -12
- package/src/icons/ast/extension-comments.ts +0 -12
- package/src/icons/ast/extension-files.ts +0 -12
- package/src/icons/ast/extension-references.ts +0 -12
- package/src/icons/ast/extension-workflow.ts +0 -12
- package/src/icons/ast/favorites-checked.ts +0 -12
- package/src/icons/ast/fibery-desktop-app.ts +0 -12
- package/src/icons/ast/field-unit.ts +0 -12
- package/src/icons/ast/figma.ts +0 -12
- package/src/icons/ast/file-broken.ts +0 -12
- package/src/icons/ast/fullscreen-mode-off-icon.ts +0 -12
- package/src/icons/ast/fullscreen-mode-on-icon.ts +0 -12
- package/src/icons/ast/gauge.ts +0 -12
- package/src/icons/ast/github.ts +0 -12
- package/src/icons/ast/gitlab.ts +0 -12
- package/src/icons/ast/globe.ts +0 -12
- package/src/icons/ast/google-drive.ts +0 -12
- package/src/icons/ast/google-map.ts +0 -12
- package/src/icons/ast/hide.ts +0 -12
- package/src/icons/ast/integrations-integration-discourse-color.ts +0 -12
- package/src/icons/ast/integrations-integration-intercom-color.ts +0 -12
- package/src/icons/ast/integrations-integration-slack-color.ts +0 -12
- package/src/icons/ast/integrations-integration-zendesk-color.ts +0 -12
- package/src/icons/ast/intercom.ts +0 -12
- package/src/icons/ast/jira.ts +0 -12
- package/src/icons/ast/left-panel.ts +0 -12
- package/src/icons/ast/level-plus.ts +0 -12
- package/src/icons/ast/lock-outline.ts +0 -12
- package/src/icons/ast/loom.ts +0 -12
- package/src/icons/ast/loupe-zoom.ts +0 -12
- package/src/icons/ast/many-people.ts +0 -12
- package/src/icons/ast/message-plus-square.ts +0 -12
- package/src/icons/ast/miro.ts +0 -12
- package/src/icons/ast/mixpanel.ts +0 -12
- package/src/icons/ast/move-bottom.ts +0 -12
- package/src/icons/ast/move-top.ts +0 -12
- package/src/icons/ast/network-add.ts +0 -12
- package/src/icons/ast/network.ts +0 -12
- package/src/icons/ast/notifications.ts +0 -12
- package/src/icons/ast/open-ai.ts +0 -12
- package/src/icons/ast/open-as-page.ts +0 -12
- package/src/icons/ast/popup.ts +0 -12
- package/src/icons/ast/posts.ts +0 -12
- package/src/icons/ast/quick-filter-personal.ts +0 -12
- package/src/icons/ast/quick-filter.ts +0 -12
- package/src/icons/ast/reply.ts +0 -12
- package/src/icons/ast/restore.ts +0 -12
- package/src/icons/ast/richeditor-actions-more.ts +0 -12
- package/src/icons/ast/richeditor-comment-create.ts +0 -12
- package/src/icons/ast/richeditor-entity-link-create.ts +0 -12
- package/src/icons/ast/richeditor-history-redo.ts +0 -12
- package/src/icons/ast/richeditor-history-undo.ts +0 -12
- package/src/icons/ast/richeditor-image-upload.ts +0 -12
- package/src/icons/ast/richeditor-image-wrap-center.ts +0 -12
- package/src/icons/ast/richeditor-image-wrap-left.ts +0 -12
- package/src/icons/ast/richeditor-image-wrap-right.ts +0 -12
- package/src/icons/ast/richeditor-image-zoom.ts +0 -12
- package/src/icons/ast/richeditor-link-create.ts +0 -12
- package/src/icons/ast/richeditor-open-link.ts +0 -12
- package/src/icons/ast/richeditor-unlink.ts +0 -12
- package/src/icons/ast/right-panel.ts +0 -12
- package/src/icons/ast/rule-scheduled.ts +0 -12
- package/src/icons/ast/settings-off.ts +0 -12
- package/src/icons/ast/shared.ts +0 -12
- package/src/icons/ast/sidebar-fields-opened.ts +0 -12
- package/src/icons/ast/sidebar-fields.ts +0 -12
- package/src/icons/ast/sidebar.ts +0 -12
- package/src/icons/ast/slack-icon.ts +0 -12
- package/src/icons/ast/slack.ts +0 -12
- package/src/icons/ast/slide-menu-close.ts +0 -12
- package/src/icons/ast/slide-menu-open.ts +0 -12
- package/src/icons/ast/sort-on-bottom.ts +0 -12
- package/src/icons/ast/sort-on-top.ts +0 -12
- package/src/icons/ast/space-list.ts +0 -12
- package/src/icons/ast/success.ts +0 -12
- package/src/icons/ast/template.ts +0 -12
- package/src/icons/ast/thumbs-down.ts +0 -12
- package/src/icons/ast/thumbs-up.ts +0 -12
- package/src/icons/ast/twitter.ts +0 -12
- package/src/icons/ast/type-boolean.ts +0 -12
- package/src/icons/ast/type-function.ts +0 -12
- package/src/icons/ast/type-id.ts +0 -12
- package/src/icons/ast/type-rule.ts +0 -12
- package/src/icons/ast/type-url.ts +0 -12
- package/src/icons/ast/units-db-badge-abbr.ts +0 -12
- package/src/icons/ast/units-db-badge-full.ts +0 -12
- package/src/icons/ast/units-db-icon.ts +0 -12
- package/src/icons/ast/unlock-outline.ts +0 -12
- package/src/icons/ast/upgrade.ts +0 -12
- package/src/icons/ast/user-check.ts +0 -12
- package/src/icons/ast/user-group-remove.ts +0 -12
- package/src/icons/ast/user-group.ts +0 -12
- package/src/icons/ast/user-role.ts +0 -12
- package/src/icons/ast/user-x.ts +0 -12
- package/src/icons/ast/windows.ts +0 -12
- package/src/icons/ast/workspace-map.ts +0 -12
- package/src/icons/ast/youtube.ts +0 -12
- package/src/icons/ast/zoom-in.ts +0 -12
- package/src/icons/ast/zoom-out.ts +0 -12
- package/src/icons/react/app-details.tsx +0 -18
- package/src/icons/react/app-store-one-color.tsx +0 -18
- package/src/icons/react/app-templates.tsx +0 -18
- package/src/icons/react/app-webhooks.tsx +0 -18
- package/src/icons/react/arrow-bottom.tsx +0 -18
- package/src/icons/react/arrow-top.tsx +0 -18
- package/src/icons/react/automations-cancelled.tsx +0 -18
- package/src/icons/react/automations-error.tsx +0 -18
- package/src/icons/react/automations-in-progress.tsx +0 -18
- package/src/icons/react/automations-not-started.tsx +0 -18
- package/src/icons/react/automations-success.tsx +0 -18
- package/src/icons/react/backlog-icon.tsx +0 -18
- package/src/icons/react/batch-actions-icon.tsx +0 -18
- package/src/icons/react/bell-filled.tsx +0 -18
- package/src/icons/react/check-circle-filled.tsx +0 -18
- package/src/icons/react/check-circle.tsx +0 -18
- package/src/icons/react/clean.tsx +0 -18
- package/src/icons/react/clear-value.tsx +0 -18
- package/src/icons/react/color-coding-filled.tsx +0 -18
- package/src/icons/react/create.tsx +0 -18
- package/src/icons/react/cross-circle.tsx +0 -18
- package/src/icons/react/database-off.tsx +0 -18
- package/src/icons/react/database-stroke.tsx +0 -18
- package/src/icons/react/demo.tsx +0 -18
- package/src/icons/react/dependency.tsx +0 -18
- package/src/icons/react/dividers.tsx +0 -18
- package/src/icons/react/document.tsx +0 -18
- package/src/icons/react/double-arrow-left.tsx +0 -18
- package/src/icons/react/double-arrow-right.tsx +0 -18
- package/src/icons/react/double-line.tsx +0 -18
- package/src/icons/react/drag-block-handle-single.tsx +0 -18
- package/src/icons/react/edit-value.tsx +0 -18
- package/src/icons/react/error-circle-filled.tsx +0 -18
- package/src/icons/react/extension-assignments.tsx +0 -18
- package/src/icons/react/extension-avatar.tsx +0 -18
- package/src/icons/react/extension-comments.tsx +0 -18
- package/src/icons/react/extension-files.tsx +0 -18
- package/src/icons/react/extension-workflow.tsx +0 -18
- package/src/icons/react/favorites-checked.tsx +0 -18
- package/src/icons/react/fibery-desktop-app.tsx +0 -18
- package/src/icons/react/field-unit.tsx +0 -18
- package/src/icons/react/figma.tsx +0 -18
- package/src/icons/react/file-broken.tsx +0 -18
- package/src/icons/react/fullscreen-mode-off-icon.tsx +0 -18
- package/src/icons/react/fullscreen-mode-on-icon.tsx +0 -18
- package/src/icons/react/gauge.tsx +0 -18
- package/src/icons/react/github.tsx +0 -18
- package/src/icons/react/gitlab.tsx +0 -18
- package/src/icons/react/globe.tsx +0 -18
- package/src/icons/react/google-drive.tsx +0 -18
- package/src/icons/react/google-map.tsx +0 -18
- package/src/icons/react/hide.tsx +0 -18
- package/src/icons/react/image-xmark.tsx +0 -18
- package/src/icons/react/info-circle-filled.tsx +0 -18
- package/src/icons/react/info-circle.tsx +0 -18
- package/src/icons/react/integrations-integration-discourse-color.tsx +0 -18
- package/src/icons/react/integrations-integration-intercom-color.tsx +0 -18
- package/src/icons/react/integrations-integration-slack-color.tsx +0 -18
- package/src/icons/react/integrations-integration-zendesk-color.tsx +0 -18
- package/src/icons/react/intercom.tsx +0 -18
- package/src/icons/react/invite-people.tsx +0 -18
- package/src/icons/react/jira.tsx +0 -18
- package/src/icons/react/left-panel.tsx +0 -18
- package/src/icons/react/level-plus.tsx +0 -18
- package/src/icons/react/lock-outline.tsx +0 -18
- package/src/icons/react/loom.tsx +0 -18
- package/src/icons/react/loupe-zoom.tsx +0 -18
- package/src/icons/react/many-people.tsx +0 -18
- package/src/icons/react/message-plus-square.tsx +0 -18
- package/src/icons/react/miro.tsx +0 -18
- package/src/icons/react/mixpanel.tsx +0 -18
- package/src/icons/react/move-bottom.tsx +0 -18
- package/src/icons/react/move-space.tsx +0 -18
- package/src/icons/react/move-top.tsx +0 -18
- package/src/icons/react/network-add.tsx +0 -18
- package/src/icons/react/network.tsx +0 -18
- package/src/icons/react/open-ai.tsx +0 -18
- package/src/icons/react/open-as-page.tsx +0 -18
- package/src/icons/react/popup.tsx +0 -18
- package/src/icons/react/posts.tsx +0 -18
- package/src/icons/react/quick-filter-personal.tsx +0 -18
- package/src/icons/react/quick-filter.tsx +0 -18
- package/src/icons/react/remove-people.tsx +0 -18
- package/src/icons/react/reply.tsx +0 -18
- package/src/icons/react/restore.tsx +0 -18
- package/src/icons/react/richeditor-actions-more.tsx +0 -18
- package/src/icons/react/richeditor-comment-create.tsx +0 -18
- package/src/icons/react/richeditor-entity-link-create.tsx +0 -18
- package/src/icons/react/richeditor-history-redo.tsx +0 -18
- package/src/icons/react/richeditor-history-undo.tsx +0 -18
- package/src/icons/react/richeditor-image-upload.tsx +0 -18
- package/src/icons/react/richeditor-image-wrap-center.tsx +0 -18
- package/src/icons/react/richeditor-image-wrap-left.tsx +0 -18
- package/src/icons/react/richeditor-image-wrap-right.tsx +0 -18
- package/src/icons/react/richeditor-image-zoom.tsx +0 -18
- package/src/icons/react/richeditor-link-create.tsx +0 -18
- package/src/icons/react/richeditor-open-link.tsx +0 -18
- package/src/icons/react/richeditor-unlink.tsx +0 -18
- package/src/icons/react/right-panel.tsx +0 -18
- package/src/icons/react/rule-scheduled.tsx +0 -18
- package/src/icons/react/send-arrow.tsx +0 -18
- package/src/icons/react/settings-off.tsx +0 -18
- package/src/icons/react/shared.tsx +0 -18
- package/src/icons/react/sidebar-fields-opened.tsx +0 -18
- package/src/icons/react/sidebar-fields.tsx +0 -18
- package/src/icons/react/sidebar.tsx +0 -18
- package/src/icons/react/slack-icon.tsx +0 -18
- package/src/icons/react/slack.tsx +0 -18
- package/src/icons/react/slide-menu-close.tsx +0 -18
- package/src/icons/react/slide-menu-open.tsx +0 -18
- package/src/icons/react/smart-folder.tsx +0 -18
- package/src/icons/react/sort-on-bottom.tsx +0 -18
- package/src/icons/react/sort-on-top.tsx +0 -18
- package/src/icons/react/space-list.tsx +0 -18
- package/src/icons/react/success.tsx +0 -18
- package/src/icons/react/suggest-integration.tsx +0 -18
- package/src/icons/react/switch-to-mention.tsx +0 -18
- package/src/icons/react/template.tsx +0 -18
- package/src/icons/react/thumbs-down.tsx +0 -18
- package/src/icons/react/thumbs-up.tsx +0 -18
- package/src/icons/react/twitter.tsx +0 -18
- package/src/icons/react/type-boolean.tsx +0 -18
- package/src/icons/react/type-function.tsx +0 -18
- package/src/icons/react/type-id.tsx +0 -18
- package/src/icons/react/type-rule.tsx +0 -18
- package/src/icons/react/type-url.tsx +0 -18
- package/src/icons/react/units-db-badge-abbr.tsx +0 -18
- package/src/icons/react/units-db-badge-full.tsx +0 -18
- package/src/icons/react/units-db-icon.tsx +0 -18
- package/src/icons/react/unlock-outline.tsx +0 -18
- package/src/icons/react/upgrade.tsx +0 -18
- package/src/icons/react/user-check.tsx +0 -18
- package/src/icons/react/user-group-remove.tsx +0 -18
- package/src/icons/react/user-group.tsx +0 -18
- package/src/icons/react/user-role.tsx +0 -18
- package/src/icons/react/user-x.tsx +0 -18
- package/src/icons/react/windows.tsx +0 -18
- package/src/icons/react/workspace-map.tsx +0 -18
- package/src/icons/react/youtube.tsx +0 -18
- package/src/icons/react/zoom-in.tsx +0 -18
- package/src/icons/react/zoom-out.tsx +0 -18
- package/src/icons/svg/ai-avatar.svg +0 -3
- package/src/icons/svg/ai-search.svg +0 -3
- package/src/icons/svg/anthropic.svg +0 -3
- package/src/icons/svg/app-store-one-color.svg +0 -4
- package/src/icons/svg/app-store.svg +0 -4
- package/src/icons/svg/app-webhooks.svg +0 -2
- package/src/icons/svg/app-wiki.svg +0 -2
- package/src/icons/svg/apple.svg +0 -4
- package/src/icons/svg/automations-cancelled.svg +0 -3
- package/src/icons/svg/automations-disabled.svg +0 -3
- package/src/icons/svg/automations-success.svg +0 -3
- package/src/icons/svg/batch-actions-icon.svg +0 -4
- package/src/icons/svg/bell-filled.svg +0 -4
- package/src/icons/svg/chat-ai.svg +0 -5
- package/src/icons/svg/chat.svg +0 -3
- package/src/icons/svg/clean.svg +0 -6
- package/src/icons/svg/color-coding-filled.svg +0 -3
- package/src/icons/svg/create.svg +0 -3
- package/src/icons/svg/cross-circle.svg +0 -4
- package/src/icons/svg/csv.svg +0 -3
- package/src/icons/svg/database-off.svg +0 -3
- package/src/icons/svg/demo.svg +0 -2
- package/src/icons/svg/dependency.svg +0 -3
- package/src/icons/svg/document.svg +0 -4
- package/src/icons/svg/double-arrow-left.svg +0 -2
- package/src/icons/svg/double-arrow-right.svg +0 -2
- package/src/icons/svg/double-line.svg +0 -3
- package/src/icons/svg/drag-block-handle-single.svg +0 -5
- package/src/icons/svg/edit-value.svg +0 -5
- package/src/icons/svg/extension/assignments.svg +0 -7
- package/src/icons/svg/file-broken.svg +0 -3
- package/src/icons/svg/fullscreen-mode-on-icon.svg +0 -3
- package/src/icons/svg/gauge.svg +0 -5
- package/src/icons/svg/globe.svg +0 -3
- package/src/icons/svg/integrations/integration-slack-color.svg +0 -10
- package/src/icons/svg/intercom.svg +0 -3
- package/src/icons/svg/left-panel.svg +0 -11
- package/src/icons/svg/level-plus.svg +0 -4
- package/src/icons/svg/lock-outline.svg +0 -5
- package/src/icons/svg/loupe-zoom.svg +0 -3
- package/src/icons/svg/message-plus-square.svg +0 -4
- package/src/icons/svg/network-add.svg +0 -5
- package/src/icons/svg/notifications.svg +0 -2
- package/src/icons/svg/open-ai.svg +0 -3
- package/src/icons/svg/open-as-page.svg +0 -3
- package/src/icons/svg/posts.svg +0 -3
- package/src/icons/svg/quick-filter-personal.svg +0 -3
- package/src/icons/svg/quick-filter.svg +0 -3
- package/src/icons/svg/reply.svg +0 -2
- package/src/icons/svg/restore.svg +0 -2
- package/src/icons/svg/richeditor/actions/more.svg +0 -2
- package/src/icons/svg/richeditor/comment/create.svg +0 -5
- package/src/icons/svg/richeditor/entity-link/create.svg +0 -2
- package/src/icons/svg/richeditor/image/wrap-center.svg +0 -2
- package/src/icons/svg/richeditor/image/wrap-left.svg +0 -2
- package/src/icons/svg/richeditor/image/wrap-right.svg +0 -2
- package/src/icons/svg/richeditor/image/zoom.svg +0 -5
- package/src/icons/svg/richeditor/link/create.svg +0 -9
- package/src/icons/svg/richeditor/mark/code.svg +0 -5
- package/src/icons/svg/richeditor/mark/em.svg +0 -3
- package/src/icons/svg/richeditor/mark/highlight.svg +0 -3
- package/src/icons/svg/richeditor/mark/strike.svg +0 -3
- package/src/icons/svg/richeditor/mark/strong.svg +0 -3
- package/src/icons/svg/richeditor/unlink.svg +0 -10
- package/src/icons/svg/right-panel.svg +0 -11
- package/src/icons/svg/rule-scheduled.svg +0 -5
- package/src/icons/svg/settings-off.svg +0 -4
- package/src/icons/svg/shared.svg +0 -7
- package/src/icons/svg/sidebar-fields-opened.svg +0 -3
- package/src/icons/svg/sidebar-fields.svg +0 -6
- package/src/icons/svg/sidebar.svg +0 -2
- package/src/icons/svg/slack-icon.svg +0 -3
- package/src/icons/svg/slide-menu-close.svg +0 -4
- package/src/icons/svg/slide-menu-open.svg +0 -4
- package/src/icons/svg/sort-on-bottom.svg +0 -4
- package/src/icons/svg/sort-on-top.svg +0 -4
- package/src/icons/svg/space-list.svg +0 -4
- package/src/icons/svg/success.svg +0 -4
- package/src/icons/svg/template.svg +0 -3
- package/src/icons/svg/thumbs-down.svg +0 -3
- package/src/icons/svg/thumbs-up.svg +0 -3
- package/src/icons/svg/type/boolean.svg +0 -2
- package/src/icons/svg/type/function.svg +0 -2
- package/src/icons/svg/type/id.svg +0 -3
- package/src/icons/svg/type/rule.svg +0 -2
- package/src/icons/svg/type/url.svg +0 -9
- package/src/icons/svg/units/db-badge-abbr.svg +0 -4
- package/src/icons/svg/units/db-badge-full.svg +0 -4
- package/src/icons/svg/units/db-icon.svg +0 -4
- package/src/icons/svg/upgrade.svg +0 -2
- package/src/icons/svg/user-check.svg +0 -3
- package/src/icons/svg/windows.svg +0 -15
- package/src/icons/svg/workspace-map.svg +0 -3
- package/src/icons/svg/zoom-out.svg +0 -7
- /package/src/icons/svg/{dividers.svg → architect.svg} +0 -0
- /package/src/icons/svg/{back.svg → arrow-back.svg} +0 -0
- /package/src/icons/svg/{send-arrow.svg → arrow-send.svg} +0 -0
- /package/src/icons/svg/{extension/avatar.svg → avatar.svg} +0 -0
- /package/src/icons/svg/{backlog-icon.svg → backlog.svg} +0 -0
- /package/src/icons/svg/{check-circle-filled.svg → circle-check-filled.svg} +0 -0
- /package/src/icons/svg/{check-circle.svg → circle-check.svg} +0 -0
- /package/src/icons/svg/{error-circle-filled.svg → circle-cross-filled.svg} +0 -0
- /package/src/icons/svg/{info-circle-filled.svg → circle-info-filled.svg} +0 -0
- /package/src/icons/svg/{info-circle.svg → circle-info.svg} +0 -0
- /package/src/icons/svg/{extension/comments.svg → comments.svg} +0 -0
- /package/src/icons/svg/{add-database.svg → database-add.svg} +0 -0
- /package/src/icons/svg/{database-stroke.svg → database-outline.svg} +0 -0
- /package/src/icons/svg/{hide.svg → eye-off.svg} +0 -0
- /package/src/icons/svg/{favorites-checked.svg → favorites-filled.svg} +0 -0
- /package/src/icons/svg/{switch-to-mention.svg → field-units-large.svg} +0 -0
- /package/src/icons/svg/{extension/files.svg → files.svg} +0 -0
- /package/src/icons/svg/{smart-folder.svg → folder-smart.svg} +0 -0
- /package/src/icons/svg/{fullscreen-mode-off-icon.svg → fullscreen-mode-off.svg} +0 -0
- /package/src/icons/svg/{add-group.svg → group-add.svg} +0 -0
- /package/src/icons/svg/{image-xmark.svg → image-error.svg} +0 -0
- /package/src/icons/svg/{add-integration.svg → integration-add.svg} +0 -0
- /package/src/icons/svg/{integrations/integration-discourse-color.svg → integration-discourse.svg} +0 -0
- /package/src/icons/svg/{fibery-desktop-app.svg → integration-fibery.svg} +0 -0
- /package/src/icons/svg/{figma.svg → integration-figma.svg} +0 -0
- /package/src/icons/svg/{github.svg → integration-github.svg} +0 -0
- /package/src/icons/svg/{gitlab.svg → integration-gitlab.svg} +0 -0
- /package/src/icons/svg/{google-drive.svg → integration-google-drive.svg} +0 -0
- /package/src/icons/svg/{google-map.svg → integration-google-map.svg} +0 -0
- /package/src/icons/svg/{integrations/integration-intercom-color.svg → integration-intercom.svg} +0 -0
- /package/src/icons/svg/{jira.svg → integration-jira.svg} +0 -0
- /package/src/icons/svg/{loom.svg → integration-loom.svg} +0 -0
- /package/src/icons/svg/{miro.svg → integration-miro.svg} +0 -0
- /package/src/icons/svg/{mixpanel.svg → integration-mixpanel.svg} +0 -0
- /package/src/icons/svg/{slack.svg → integration-slack.svg} +0 -0
- /package/src/icons/svg/{suggest-integration.svg → integration-suggest.svg} +0 -0
- /package/src/icons/svg/{twitter.svg → integration-twitter.svg} +0 -0
- /package/src/icons/svg/{youtube.svg → integration-youtube.svg} +0 -0
- /package/src/icons/svg/{integrations/integration-zendesk-color.svg → integration-zendesk.svg} +0 -0
- /package/src/icons/svg/{move-bottom.svg → move-down.svg} +0 -0
- /package/src/icons/svg/{move-top.svg → move-up.svg} +0 -0
- /package/src/icons/svg/{popup.svg → open-in-panel.svg} +0 -0
- /package/src/icons/svg/{richeditor/open-link.svg → open-link.svg} +0 -0
- /package/src/icons/svg/{many-people.svg → people-all.svg} +0 -0
- /package/src/icons/svg/{user-group-remove.svg → people-group-remove.svg} +0 -0
- /package/src/icons/svg/{invite-people.svg → people-invite.svg} +0 -0
- /package/src/icons/svg/{remove-people.svg → people-remove.svg} +0 -0
- /package/src/icons/svg/{user-x.svg → people-x.svg} +0 -0
- /package/src/icons/svg/{zoom-in.svg → plus.svg} +0 -0
- /package/src/icons/svg/{app-details.svg → preferences.svg} +0 -0
- /package/src/icons/svg/{network.svg → propagate.svg} +0 -0
- /package/src/icons/svg/{add-reactions.svg → reactions-add.svg} +0 -0
- /package/src/icons/svg/{richeditor/history/redo.svg → redo.svg} +0 -0
- /package/src/icons/svg/{extension/references.svg → references.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/callout.svg → richeditor-block-callout.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/code.svg → richeditor-block-code.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/embed.svg → richeditor-block-embed.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/entity.svg → richeditor-block-entity.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/file.svg → richeditor-block-file.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/h1.svg → richeditor-block-h1.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/h2.svg → richeditor-block-h2.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/h3.svg → richeditor-block-h3.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/h4.svg → richeditor-block-h4.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/mention.svg → richeditor-block-mention.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/paragraph.svg → richeditor-block-paragraph.svg} +0 -0
- /package/src/icons/svg/{richeditor/block/quote.svg → richeditor-block-quote.svg} +0 -0
- /package/src/icons/svg/{richeditor/checklist/create.svg → richeditor-checklist-create.svg} +0 -0
- /package/src/icons/svg/{richeditor/image/align-center.svg → richeditor-image-align-center.svg} +0 -0
- /package/src/icons/svg/{richeditor/image/align-left.svg → richeditor-image-align-left.svg} +0 -0
- /package/src/icons/svg/{richeditor/image/align-right.svg → richeditor-image-align-right.svg} +0 -0
- /package/src/icons/svg/{richeditor/image/upload.svg → richeditor-image.svg} +0 -0
- /package/src/icons/svg/{richeditor/linkedhighlight/create.svg → richeditor-linkedhighlight-create.svg} +0 -0
- /package/src/icons/svg/{richeditor/list/bullet.svg → richeditor-list-bullet.svg} +0 -0
- /package/src/icons/svg/{richeditor/list/ordered.svg → richeditor-list-ordered.svg} +0 -0
- /package/src/icons/svg/{richeditor/list/unindent.svg → richeditor-list-unindent.svg} +0 -0
- /package/src/icons/svg/{richeditor/mark/text-background-color.svg → richeditor-mark-text-background-color.svg} +0 -0
- /package/src/icons/svg/{richeditor/mark/underline.svg → richeditor-mark-underline.svg} +0 -0
- /package/src/icons/svg/{richeditor/table/create.svg → richeditor-table-create.svg} +0 -0
- /package/src/icons/svg/{richeditor/video/upload.svg → richeditor-video-upload.svg} +0 -0
- /package/src/icons/svg/{bolt.svg → rule.svg} +0 -0
- /package/src/icons/svg/{app-templates.svg → space-add.svg} +0 -0
- /package/src/icons/svg/{move-space.svg → space-move.svg} +0 -0
- /package/src/icons/svg/{type/button.svg → type-button.svg} +0 -0
- /package/src/icons/svg/{type/checkbox.svg → type-checkbox.svg} +0 -0
- /package/src/icons/svg/{type/date.svg → type-date.svg} +0 -0
- /package/src/icons/svg/{type/email.svg → type-email.svg} +0 -0
- /package/src/icons/svg/{type/emoji.svg → type-emoji.svg} +0 -0
- /package/src/icons/svg/{type/formula.svg → type-formula.svg} +0 -0
- /package/src/icons/svg/{type/location.svg → type-location.svg} +0 -0
- /package/src/icons/svg/{type/lookup.svg → type-lookup.svg} +0 -0
- /package/src/icons/svg/{type/money.svg → type-money.svg} +0 -0
- /package/src/icons/svg/{type/multi-select.svg → type-multi-select.svg} +0 -0
- /package/src/icons/svg/{type/number.svg → type-number.svg} +0 -0
- /package/src/icons/svg/{type/percent.svg → type-percent.svg} +0 -0
- /package/src/icons/svg/{type/phone.svg → type-phone.svg} +0 -0
- /package/src/icons/svg/{type/relation.svg → type-relation.svg} +0 -0
- /package/src/icons/svg/{type/rich-text.svg → type-rich-text.svg} +0 -0
- /package/src/icons/svg/{type/single-select.svg → type-single-select.svg} +0 -0
- /package/src/icons/svg/{type/text.svg → type-text.svg} +0 -0
- /package/src/icons/svg/{richeditor/history/undo.svg → undo.svg} +0 -0
- /package/src/icons/svg/{units/avatar.svg → units-avatar.svg} +0 -0
- /package/src/icons/svg/{units/collection.svg → units-collection.svg} +0 -0
- /package/src/icons/svg/{units/counter.svg → units-counter.svg} +0 -0
- /package/src/icons/svg/{units/date.svg → units-date.svg} +0 -0
- /package/src/icons/svg/{units/field-icon-button.svg → units-field-icon-button.svg} +0 -0
- /package/src/icons/svg/{units/field.svg → units-field.svg} +0 -0
- /package/src/icons/svg/{units/input.svg → units-input.svg} +0 -0
- /package/src/icons/svg/{field-unit.svg → units-normal.svg} +0 -0
- /package/src/icons/svg/{units/progress-bar.svg → units-progress-bar.svg} +0 -0
- /package/src/icons/svg/{units/rich-text.svg → units-rich-text.svg} +0 -0
- /package/src/icons/svg/{units/snippet.svg → units-snippet.svg} +0 -0
- /package/src/icons/svg/{unlock-outline.svg → unlock.svg} +0 -0
- /package/src/icons/svg/{clear-value.svg → value-clear.svg} +0 -0
- /package/src/icons/svg/{extension/workflow.svg → workflow.svg} +0 -0
package/src/palettes/testkit.ts
CHANGED
|
@@ -1,16 +1,25 @@
|
|
|
1
1
|
import {isRecord} from "@fibery/helpers/src/_";
|
|
2
2
|
|
|
3
3
|
import {calcLc} from "../apca";
|
|
4
|
-
import {
|
|
4
|
+
import {avatarSwatches} from "../avatar-colors";
|
|
5
|
+
import {backgrounds, type CanvasColorRole, darkFromLight, sections, stickers} from "../canvas-colors";
|
|
5
6
|
import {inspectColor, type Opts} from "../color-inspect";
|
|
6
|
-
import {
|
|
7
|
+
import {
|
|
8
|
+
colorFromUnsafe,
|
|
9
|
+
cssFromColor,
|
|
10
|
+
flattenAlpha,
|
|
11
|
+
isValidColor,
|
|
12
|
+
mixSrgb,
|
|
13
|
+
produceColor,
|
|
14
|
+
serializeHexVariadic,
|
|
15
|
+
} from "../color-utils";
|
|
7
16
|
import {defsFromPalette} from "../design-system/colors";
|
|
8
17
|
import {enumFgCustomColorPercent, enumFgTextColorPercent} from "../design-system/colors-css";
|
|
9
18
|
import {Swatch, swatches} from "../design-system/colors-swatches";
|
|
10
19
|
import {mapDef} from "../design-system/def";
|
|
11
|
-
import type {Theme} from "../design-system/theme
|
|
20
|
+
import type {Theme} from "../design-system/theme";
|
|
12
21
|
import type {ThemePalette} from "../design-system/types";
|
|
13
|
-
import {withColorDiff} from "./diff-colors";
|
|
22
|
+
import {renderLc, withColorDiff} from "./diff-colors";
|
|
14
23
|
|
|
15
24
|
const COLOR_PREFIXES = ["rgba(", "rgb(", "hsla(", "hsl("] as const;
|
|
16
25
|
const HEX_CHARS = "0123456789abcdefABCDEF";
|
|
@@ -19,16 +28,25 @@ function sealBuf(str: string) {
|
|
|
19
28
|
return str.padEnd("0 8px 20px -4px ".length, " ");
|
|
20
29
|
}
|
|
21
30
|
|
|
31
|
+
function isInformationalSuffix(str: string) {
|
|
32
|
+
return /^ \| .+$/.test(str.trimEnd());
|
|
33
|
+
}
|
|
34
|
+
|
|
22
35
|
function replaceColorsInString(str: string, opts?: Opts) {
|
|
23
36
|
const result: string[] = [];
|
|
24
37
|
let buf = "";
|
|
25
38
|
const seenColors = new Set<string>();
|
|
26
|
-
function add(verbose: string) {
|
|
39
|
+
function add(verbose: string, alignEmptyPrefix = true) {
|
|
27
40
|
const seen = seenColors.has(verbose);
|
|
28
41
|
seenColors.add(verbose);
|
|
29
|
-
|
|
42
|
+
const prefix = alignEmptyPrefix || buf || result.length > 0 ? sealBuf(buf) : "";
|
|
43
|
+
result.push(prefix + verbose + (seen ? "(SAME!)" : ""));
|
|
30
44
|
buf = "";
|
|
31
45
|
}
|
|
46
|
+
function addInformationalSuffix(from: number) {
|
|
47
|
+
result[result.length - 1] += str.slice(from);
|
|
48
|
+
return result.length === 1 ? result[0] : result;
|
|
49
|
+
}
|
|
32
50
|
|
|
33
51
|
let i = 0;
|
|
34
52
|
while (i < str.length) {
|
|
@@ -39,8 +57,12 @@ function replaceColorsInString(str: string, opts?: Opts) {
|
|
|
39
57
|
if (closeIdx !== -1) {
|
|
40
58
|
const candidate = str.slice(i, closeIdx + 1);
|
|
41
59
|
if (isValidColor(candidate)) {
|
|
42
|
-
add(inspectColor(candidate, opts));
|
|
43
60
|
i = closeIdx + 1;
|
|
61
|
+
if (str.startsWith(" | ", i)) {
|
|
62
|
+
add(inspectColor(candidate, opts), false);
|
|
63
|
+
return addInformationalSuffix(i);
|
|
64
|
+
}
|
|
65
|
+
add(inspectColor(candidate, opts));
|
|
44
66
|
continue;
|
|
45
67
|
}
|
|
46
68
|
}
|
|
@@ -52,8 +74,12 @@ function replaceColorsInString(str: string, opts?: Opts) {
|
|
|
52
74
|
}
|
|
53
75
|
const candidate = str.slice(i, end);
|
|
54
76
|
if (candidate.length >= 4 && isValidColor(candidate)) {
|
|
55
|
-
add(inspectColor(candidate, opts));
|
|
56
77
|
i = end;
|
|
78
|
+
if (str.startsWith(" | ", i)) {
|
|
79
|
+
add(inspectColor(candidate, opts), false);
|
|
80
|
+
return addInformationalSuffix(i);
|
|
81
|
+
}
|
|
82
|
+
add(inspectColor(candidate, opts));
|
|
57
83
|
continue;
|
|
58
84
|
}
|
|
59
85
|
}
|
|
@@ -72,6 +98,10 @@ function replaceColorsInString(str: string, opts?: Opts) {
|
|
|
72
98
|
if (result.length === 0) {
|
|
73
99
|
return buf;
|
|
74
100
|
}
|
|
101
|
+
if (isInformationalSuffix(buf)) {
|
|
102
|
+
result[result.length - 1] += buf;
|
|
103
|
+
return result.length === 1 ? result[0] : result;
|
|
104
|
+
}
|
|
75
105
|
result.push(sealBuf(buf));
|
|
76
106
|
}
|
|
77
107
|
return result.length === 1 ? result[0] : result;
|
|
@@ -137,6 +167,23 @@ export function userColorChoices<
|
|
|
137
167
|
);
|
|
138
168
|
}
|
|
139
169
|
|
|
170
|
+
export function avatarColorChoices<
|
|
171
|
+
T extends
|
|
172
|
+
| string
|
|
173
|
+
| Readonly<Record<string, string>>
|
|
174
|
+
| readonly string[]
|
|
175
|
+
| ReadonlyArray<readonly [string, string] | Readonly<Record<string, string>>>,
|
|
176
|
+
>(fn: (color: string) => T) {
|
|
177
|
+
const swatchKey = makeSwatchKey();
|
|
178
|
+
const globalIndex = new Map(swatches.map((c, i) => [c, i] as const));
|
|
179
|
+
return withColorDiff(
|
|
180
|
+
Object.fromEntries([
|
|
181
|
+
...avatarSwatches.map((c) => [swatchKey(c, globalIndex.get(c) ?? -1), deepMapColors(fn(c))] as const),
|
|
182
|
+
["neutral aka Swatch.Grey (no-access)", deepMapColors(fn(Swatch.Grey))] as const,
|
|
183
|
+
])
|
|
184
|
+
);
|
|
185
|
+
}
|
|
186
|
+
|
|
140
187
|
export function makeSwatchKey() {
|
|
141
188
|
const swatchNameByValue = new Map<string, string>(Object.entries(Swatch).map(([k, v]) => [v, k]));
|
|
142
189
|
const nameWidth = Math.max(...swatches.map((x) => (swatchNameByValue.get(x) ?? "").length));
|
|
@@ -156,11 +203,12 @@ export function colors(palette: ThemePalette) {
|
|
|
156
203
|
return `${prefix}[${String(i).padStart(width, " ")}]`;
|
|
157
204
|
}
|
|
158
205
|
|
|
159
|
-
function pairs(colors:
|
|
206
|
+
function pairs(colors: readonly string[], prefix: string, role: CanvasColorRole) {
|
|
160
207
|
const width = indexWidth(colors.length);
|
|
161
208
|
return Object.fromEntries(
|
|
162
|
-
colors.map((
|
|
163
|
-
|
|
209
|
+
colors.map((light, i) => {
|
|
210
|
+
const def: [string, string] = [light, darkFromLight(light, role)];
|
|
211
|
+
return [key(prefix, i, width), mapDef(def, defs.fns.deneutralize)];
|
|
164
212
|
})
|
|
165
213
|
);
|
|
166
214
|
}
|
|
@@ -177,9 +225,9 @@ export function colors(palette: ThemePalette) {
|
|
|
177
225
|
return [swatchKey(x, i), lightColor];
|
|
178
226
|
})
|
|
179
227
|
),
|
|
180
|
-
...pairs(stickers, "_.canvas.stickers"),
|
|
181
|
-
...pairs(sections, "_.canvas.sections"),
|
|
182
|
-
...pairs(backgrounds, "_.canvas.backgrounds"),
|
|
228
|
+
...pairs(stickers, "_.canvas.stickers", "sticker"),
|
|
229
|
+
...pairs(sections, "_.canvas.sections", "section"),
|
|
230
|
+
...pairs(backgrounds, "_.canvas.backgrounds", "bg"),
|
|
183
231
|
};
|
|
184
232
|
return deepMapColors(colors);
|
|
185
233
|
}
|
|
@@ -197,17 +245,25 @@ const getEnumTextColor = (theme: Theme, c: string) =>
|
|
|
197
245
|
enumFgTextColorPercent / (enumFgCustomColorPercent + enumFgTextColorPercent)
|
|
198
246
|
);
|
|
199
247
|
|
|
200
|
-
|
|
201
|
-
|
|
248
|
+
type LcReference = {
|
|
249
|
+
color: string;
|
|
250
|
+
label?: string;
|
|
251
|
+
};
|
|
252
|
+
|
|
253
|
+
function renderReference({color, label}: LcReference) {
|
|
254
|
+
return [serializeHexVariadic(color) ?? color, label].filter(Boolean).join(" ");
|
|
202
255
|
}
|
|
203
256
|
|
|
204
|
-
function
|
|
257
|
+
function withLc(fg: string, bg: LcReference) {
|
|
258
|
+
return `${fg} | ${renderLc(calcLc(fg, bg.color))} over ${renderReference(bg)}`;
|
|
259
|
+
}
|
|
260
|
+
function enumTest(cardSurface: LcReference, cardColorCoding: string | null, theme: Theme, c: string) {
|
|
205
261
|
const enumBg = theme.fns.enum(c, cardColorCoding).bg;
|
|
206
262
|
const enumFg = getEnumTextColor(theme, c);
|
|
207
263
|
|
|
208
264
|
return {
|
|
209
|
-
bg:
|
|
210
|
-
fg:
|
|
265
|
+
bg: withLc(enumBg, cardSurface),
|
|
266
|
+
fg: withLc(enumFg, {color: enumBg, label: "bg"}),
|
|
211
267
|
};
|
|
212
268
|
}
|
|
213
269
|
|
|
@@ -222,8 +278,8 @@ export function enumBgCases(theme: Theme) {
|
|
|
222
278
|
);
|
|
223
279
|
|
|
224
280
|
return {
|
|
225
|
-
overDefaultSurface: (c: string) => enumTest(adaptDefaultSurface, null, theme, c),
|
|
226
|
-
overColorCoding: (c: string) => enumTest(paintedSurface(c), c, theme, c),
|
|
227
|
-
overSameColor: (c: string) => enumTest(c, c, theme, c),
|
|
281
|
+
overDefaultSurface: (c: string) => enumTest({color: adaptDefaultSurface, label: "panelBg"}, null, theme, c),
|
|
282
|
+
overColorCoding: (c: string) => enumTest({color: paintedSurface(c), label: "paintedSurface"}, c, theme, c),
|
|
283
|
+
overSameColor: (c: string) => enumTest({color: c, label: "card"}, c, theme, c),
|
|
228
284
|
};
|
|
229
285
|
}
|
package/src/phone.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import {isFlagPresent} from "./flags";
|
|
2
|
+
import {getMediaQueryList} from "./media-query-utils";
|
|
3
|
+
|
|
4
|
+
declare global {
|
|
5
|
+
const __DISABLE_VERTICAL_MOBILE_BREAKPOINT__: boolean | undefined;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export const isPhoneApp = () =>
|
|
9
|
+
Boolean(
|
|
10
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
11
|
+
// @ts-ignore - injected by consumer app
|
|
12
|
+
window.__FIBERY_MOBILE_APP_API
|
|
13
|
+
);
|
|
14
|
+
|
|
15
|
+
const disableStatic =
|
|
16
|
+
typeof __DISABLE_VERTICAL_MOBILE_BREAKPOINT__ !== "undefined" && __DISABLE_VERTICAL_MOBILE_BREAKPOINT__;
|
|
17
|
+
const disableDynamic = disableStatic || isFlagPresent("no-vertical-mobile-breakpoint");
|
|
18
|
+
const heightIgnored = "(max-width: 450px)";
|
|
19
|
+
const heightPresent = "(max-width: 450px), (max-height: 450px)";
|
|
20
|
+
|
|
21
|
+
export const phoneMediaQuery = disableStatic ? heightIgnored : heightPresent;
|
|
22
|
+
|
|
23
|
+
export const phoneMediaQueryDynamic = disableDynamic ? heightIgnored : heightPresent;
|
|
24
|
+
|
|
25
|
+
export function isPhoneMode() {
|
|
26
|
+
return isPhoneApp() || getMediaQueryList(phoneMediaQueryDynamic).matches;
|
|
27
|
+
}
|
|
@@ -8,7 +8,7 @@ import {IconButton} from "../button/icon-button";
|
|
|
8
8
|
import {layout, space, themeVars} from "../design-system";
|
|
9
9
|
import {type EmojiPickerProps} from "../emoji-picker/emoji-picker";
|
|
10
10
|
import {useResponsiveEmojiSize} from "../emoji-picker/use-responsive-emoji-size";
|
|
11
|
-
import
|
|
11
|
+
import ReactionsAdd from "../icons/react/reactions-add";
|
|
12
12
|
import {mobileRootSelector} from "../mobile-styles";
|
|
13
13
|
import {Popover} from "../popover";
|
|
14
14
|
import {ToggleButton} from "../toggle-button/toggle-button";
|
|
@@ -91,7 +91,7 @@ export const ReactionPicker = ({mode, onSelect, open, onOpenChange, EmojiPicker}
|
|
|
91
91
|
paddingInline: 0,
|
|
92
92
|
}}
|
|
93
93
|
>
|
|
94
|
-
<
|
|
94
|
+
<ReactionsAdd iconSize={isPhone ? 20 : 16} />
|
|
95
95
|
</ToggleButton>
|
|
96
96
|
) : (
|
|
97
97
|
<IconButton
|
|
@@ -103,7 +103,7 @@ export const ReactionPicker = ({mode, onSelect, open, onOpenChange, EmojiPicker}
|
|
|
103
103
|
size="small"
|
|
104
104
|
supportMobile
|
|
105
105
|
>
|
|
106
|
-
<
|
|
106
|
+
<ReactionsAdd />
|
|
107
107
|
</IconButton>
|
|
108
108
|
)}
|
|
109
109
|
</Tooltip>
|
|
@@ -2,7 +2,7 @@ import {css, cx} from "@linaria/core";
|
|
|
2
2
|
import {type ReactNode} from "react";
|
|
3
3
|
|
|
4
4
|
import {border, space, themeVars} from "./design-system";
|
|
5
|
-
import
|
|
5
|
+
import ImageError from "./icons/react/image-error";
|
|
6
6
|
|
|
7
7
|
export const richTextEmbedErrorStyle = css`
|
|
8
8
|
min-height: 380px;
|
|
@@ -41,7 +41,7 @@ type Props = {
|
|
|
41
41
|
export const RichTextEmbedError = ({isSelected, label}: Props) => {
|
|
42
42
|
return (
|
|
43
43
|
<div className={cx(richTextEmbedErrorStyle, isSelected && selectedStyle)}>
|
|
44
|
-
<
|
|
44
|
+
<ImageError iconSize={32} color={themeVars.disabledTextColor} />
|
|
45
45
|
<div className={textStyle}>{label}</div>
|
|
46
46
|
</div>
|
|
47
47
|
);
|
|
@@ -12,7 +12,6 @@ import {
|
|
|
12
12
|
} from "./theme-provider";
|
|
13
13
|
import {storeWarmPreference} from "./theme-settings";
|
|
14
14
|
import {locateThemeBundle} from "./theme-styles";
|
|
15
|
-
import {prefix as themePrefix} from "./theming.generated";
|
|
16
15
|
|
|
17
16
|
const {
|
|
18
17
|
palette,
|
|
@@ -185,9 +184,9 @@ describe("RootThemeProvider", () => {
|
|
|
185
184
|
|
|
186
185
|
describe("diff optimization integrity", () => {
|
|
187
186
|
it("RootThemeProvider internal ThemeProvider only sets diff from base", () => {
|
|
188
|
-
const lightStyles = stylesFromTheme(themeLight
|
|
187
|
+
const lightStyles = stylesFromTheme(themeLight);
|
|
189
188
|
const lightTheme = themeFromPalette(palette, "light");
|
|
190
|
-
const actualStyles = stylesFromTheme(lightTheme
|
|
189
|
+
const actualStyles = stylesFromTheme(lightTheme);
|
|
191
190
|
|
|
192
191
|
// Count expected diff (theme from getThemeColors vs defaultLightTheme)
|
|
193
192
|
let expectedDiffCount = 0;
|
|
@@ -2,10 +2,11 @@ import {useControllableState} from "@fibery/react/src/use-controllable-state";
|
|
|
2
2
|
import {Wrap} from "@fibery/react/src/wrap";
|
|
3
3
|
import {css, cx} from "@linaria/core";
|
|
4
4
|
import type {ForwardedRef, ReactNode, RefObject} from "react";
|
|
5
|
-
import React, {forwardRef, useCallback, useImperativeHandle, useMemo, useRef, useState} from "react";
|
|
5
|
+
import React, {forwardRef, isValidElement, useCallback, useImperativeHandle, useMemo, useRef, useState} from "react";
|
|
6
6
|
import type {SelectInstance} from "react-select";
|
|
7
7
|
|
|
8
8
|
import {space, textClasses} from "../design-system";
|
|
9
|
+
import {MobileDrawer} from "../mobile-drawer";
|
|
9
10
|
import type {Placement} from "../popover";
|
|
10
11
|
import {Popover} from "../popover";
|
|
11
12
|
import {useIsPhone} from "../use-is-phone";
|
|
@@ -42,6 +43,7 @@ export const popupClassName = css`
|
|
|
42
43
|
const mobileClassName = css`
|
|
43
44
|
display: grid;
|
|
44
45
|
min-height: 0;
|
|
46
|
+
height: 100%;
|
|
45
47
|
padding-top: ${space.s12}px;
|
|
46
48
|
padding-left: ${space.s12}px;
|
|
47
49
|
padding-right: ${space.s12}px;
|
|
@@ -192,6 +194,42 @@ function SelectInPopoverInner<T, U extends boolean, V extends GroupBase<T>>(
|
|
|
192
194
|
...components,
|
|
193
195
|
};
|
|
194
196
|
|
|
197
|
+
const select = (
|
|
198
|
+
<SelectControlSettingsProvider inPopover={true} getPopupContainerElement={undefined}>
|
|
199
|
+
<ReactSelect<T, U, V>
|
|
200
|
+
{...rest}
|
|
201
|
+
autoFocus={isPhone ? false : rest.autoFocus}
|
|
202
|
+
ref={selectRef}
|
|
203
|
+
styles={composedStyles}
|
|
204
|
+
onKeyDown={onSelectKeyDown}
|
|
205
|
+
closeMenuOnSelect={false}
|
|
206
|
+
onChange={handleChange}
|
|
207
|
+
menuIsOpen
|
|
208
|
+
maxMenuHeight={maxMenuHeight}
|
|
209
|
+
disabled={disabled}
|
|
210
|
+
isCollectionMode={isCollectionMode}
|
|
211
|
+
isClearable={!isCollectionMode && isClearable}
|
|
212
|
+
{...otherSelectProps}
|
|
213
|
+
components={selectComponents}
|
|
214
|
+
inline
|
|
215
|
+
/>
|
|
216
|
+
</SelectControlSettingsProvider>
|
|
217
|
+
);
|
|
218
|
+
|
|
219
|
+
if (isPhone) {
|
|
220
|
+
return (
|
|
221
|
+
<MobileDrawer
|
|
222
|
+
open={visible}
|
|
223
|
+
onOpenChange={onOpenChange}
|
|
224
|
+
title={title ?? ""}
|
|
225
|
+
trigger={isValidElement(trigger) ? trigger : undefined}
|
|
226
|
+
triggerRef={setTriggerElement}
|
|
227
|
+
>
|
|
228
|
+
<div className={mobileClassName}>{select}</div>
|
|
229
|
+
</MobileDrawer>
|
|
230
|
+
);
|
|
231
|
+
}
|
|
232
|
+
|
|
195
233
|
return (
|
|
196
234
|
<Popover.Root open={visible} onOpenChange={onOpenChange}>
|
|
197
235
|
<Popover.Trigger ref={setTriggerElement} asChild triggerEvent="click">
|
|
@@ -199,36 +237,14 @@ function SelectInPopoverInner<T, U extends boolean, V extends GroupBase<T>>(
|
|
|
199
237
|
</Popover.Trigger>
|
|
200
238
|
<Wrap with={Popover.Portal} if={renderInPortal}>
|
|
201
239
|
<Popover.Content
|
|
202
|
-
supportMobile
|
|
203
240
|
title={title}
|
|
204
241
|
offset={offset}
|
|
205
242
|
popupContainerClassName={cx(defaultPopupContainerClassName, popupContainerClassName)}
|
|
206
243
|
popupClassName={cx(popupClassName, popupStyles)}
|
|
207
|
-
mobilePopupContentClassName={mobileClassName}
|
|
208
244
|
placement={popoverPlacement}
|
|
209
245
|
>
|
|
210
|
-
{title &&
|
|
211
|
-
{
|
|
212
|
-
{/*Render target in controlled by Popover here. So we just override SelectControlContext here and set popupContainerElement to undefined. */}
|
|
213
|
-
{/*So in dom react-select will be a child of popover. */}
|
|
214
|
-
<SelectControlSettingsProvider inPopover={true} getPopupContainerElement={undefined}>
|
|
215
|
-
<ReactSelect<T, U, V>
|
|
216
|
-
{...rest}
|
|
217
|
-
ref={selectRef}
|
|
218
|
-
styles={composedStyles}
|
|
219
|
-
onKeyDown={onSelectKeyDown}
|
|
220
|
-
closeMenuOnSelect={false}
|
|
221
|
-
onChange={handleChange}
|
|
222
|
-
menuIsOpen
|
|
223
|
-
maxMenuHeight={maxMenuHeight}
|
|
224
|
-
disabled={disabled}
|
|
225
|
-
isCollectionMode={isCollectionMode}
|
|
226
|
-
isClearable={!isCollectionMode && isClearable}
|
|
227
|
-
{...otherSelectProps}
|
|
228
|
-
components={selectComponents}
|
|
229
|
-
inline
|
|
230
|
-
/>
|
|
231
|
-
</SelectControlSettingsProvider>
|
|
246
|
+
{title && <div className={cx(textClasses.heading6, titleClassName)}>{title}</div>}
|
|
247
|
+
{select}
|
|
232
248
|
</Popover.Content>
|
|
233
249
|
</Wrap>
|
|
234
250
|
</Popover.Root>
|
package/src/select/util.ts
CHANGED
|
@@ -29,5 +29,5 @@ export function countOptions<Option, Group extends GroupBase<Option>>(
|
|
|
29
29
|
}, 0);
|
|
30
30
|
}
|
|
31
31
|
export function isPureTextChildren(children: ReactNode) {
|
|
32
|
-
return !Children.toArray(children).
|
|
32
|
+
return !Children.toArray(children).some((child) => !(typeof child === "string" || typeof child === "number"));
|
|
33
33
|
}
|
package/src/thematic.tsx
CHANGED
|
@@ -3,7 +3,7 @@ import {useState} from "react";
|
|
|
3
3
|
import {createPortal} from "react-dom";
|
|
4
4
|
|
|
5
5
|
import {IconButton} from "./button/icon-button";
|
|
6
|
-
import {backgrounds, sections, stickers} from "./canvas-colors";
|
|
6
|
+
import {backgrounds, type CanvasColorRole, darkFromLight, sections, stickers} from "./canvas-colors";
|
|
7
7
|
import {inspectColor} from "./color-inspect";
|
|
8
8
|
import {border, type ColorScale, space, themeVars} from "./design-system";
|
|
9
9
|
import {cardTypeColors} from "./design-system/colors";
|
|
@@ -16,7 +16,7 @@ import Lab from "./icons/react/lab";
|
|
|
16
16
|
import Pin from "./icons/react/pin";
|
|
17
17
|
import PinFilled from "./icons/react/pin-filled";
|
|
18
18
|
import Refresh from "./icons/react/refresh";
|
|
19
|
-
import
|
|
19
|
+
import Undo from "./icons/react/undo";
|
|
20
20
|
import {selectPalette} from "./palette-generator";
|
|
21
21
|
import type {InspectChannel} from "./thematic-color-picker";
|
|
22
22
|
import {themeIcons} from "./thematic-constants";
|
|
@@ -153,17 +153,18 @@ export function Thematic() {
|
|
|
153
153
|
const dn = state.palette.deneutralize ? theme.fns.deneutralize : (c: string) => c;
|
|
154
154
|
const isDark = state.showDark;
|
|
155
155
|
const canvasCol = (
|
|
156
|
-
defs: readonly
|
|
156
|
+
defs: readonly string[],
|
|
157
157
|
label: string,
|
|
158
|
+
role: CanvasColorRole,
|
|
158
159
|
padBefore?: Record<number, number>
|
|
159
160
|
) => {
|
|
160
161
|
const scale: (string | null)[] = [];
|
|
161
|
-
defs.forEach((
|
|
162
|
+
defs.forEach((light, i) => {
|
|
162
163
|
const pad = padBefore?.[i] ?? 0;
|
|
163
164
|
for (let p = 0; p < pad; p++) {
|
|
164
165
|
scale.push(SPACER);
|
|
165
166
|
}
|
|
166
|
-
scale.push(dn(isDark ?
|
|
167
|
+
scale.push(dn(isDark ? darkFromLight(light, role) : light));
|
|
167
168
|
});
|
|
168
169
|
return {
|
|
169
170
|
name: label,
|
|
@@ -229,9 +230,9 @@ export function Thematic() {
|
|
|
229
230
|
altColors: state.isAltPressed ? [...cardTypeColors] : undefined,
|
|
230
231
|
mini: true,
|
|
231
232
|
},
|
|
232
|
-
canvasCol(backgrounds, "background"),
|
|
233
|
-
canvasCol(stickers, "sticker", {0: 1, 8: 2}),
|
|
234
|
-
canvasCol(sections, "section"),
|
|
233
|
+
canvasCol(backgrounds, "background", "bg"),
|
|
234
|
+
canvasCol(stickers, "sticker", "sticker", {0: 1, 8: 2}),
|
|
235
|
+
canvasCol(sections, "section", "section"),
|
|
235
236
|
];
|
|
236
237
|
};
|
|
237
238
|
const panel = (
|
|
@@ -496,7 +497,7 @@ export function Thematic() {
|
|
|
496
497
|
onMouseEnter={() => state.setPreviewPalette(null)}
|
|
497
498
|
title="Defaults"
|
|
498
499
|
>
|
|
499
|
-
<
|
|
500
|
+
<Undo />
|
|
500
501
|
</IconButton>
|
|
501
502
|
) : null}
|
|
502
503
|
{(() => {
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
useThemeStyles,
|
|
12
12
|
} from "./theme-provider";
|
|
13
13
|
import {locateThemeBundle} from "./theme-styles";
|
|
14
|
-
import {neutralStyles
|
|
14
|
+
import {neutralStyles} from "./theming.generated";
|
|
15
15
|
|
|
16
16
|
const {
|
|
17
17
|
palette,
|
|
@@ -79,8 +79,8 @@ describe("ThemeProvider", () => {
|
|
|
79
79
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
80
80
|
|
|
81
81
|
// Compare full inline themes to verify they differ
|
|
82
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
83
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
82
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
83
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
84
84
|
|
|
85
85
|
// Count how many properties differ between light and dark
|
|
86
86
|
let diffCount = 0;
|
|
@@ -117,8 +117,8 @@ describe("ThemeProvider", () => {
|
|
|
117
117
|
const theme3 = themeFromPalette(palette, "light"); // back to light
|
|
118
118
|
|
|
119
119
|
// Verify themes differ
|
|
120
|
-
const styles1 = stylesFromTheme(theme1
|
|
121
|
-
const styles2 = stylesFromTheme(theme2
|
|
120
|
+
const styles1 = stylesFromTheme(theme1);
|
|
121
|
+
const styles2 = stylesFromTheme(theme2);
|
|
122
122
|
|
|
123
123
|
let diffCount = 0;
|
|
124
124
|
for (const key in styles2) {
|
|
@@ -199,8 +199,8 @@ describe("ThemeProvider", () => {
|
|
|
199
199
|
const lightTheme = themeFromPalette(palette, "light");
|
|
200
200
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
201
201
|
|
|
202
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
203
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
202
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
203
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
204
204
|
|
|
205
205
|
let diffCount = 0;
|
|
206
206
|
for (const key in darkStyles) {
|
|
@@ -359,8 +359,8 @@ describe("ThemeProvider", () => {
|
|
|
359
359
|
const lightTheme = themeFromPalette(palette, "light");
|
|
360
360
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
361
361
|
|
|
362
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
363
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
362
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
363
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
364
364
|
|
|
365
365
|
// Calculate light→dark diff
|
|
366
366
|
const lightToDarkDiff: Record<string, string> = {};
|
|
@@ -386,11 +386,11 @@ describe("ThemeProvider", () => {
|
|
|
386
386
|
const lightTheme = themeFromPalette(palette, "light");
|
|
387
387
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
388
388
|
|
|
389
|
-
const fullStyles = stylesFromTheme(darkTheme
|
|
389
|
+
const fullStyles = stylesFromTheme(darkTheme);
|
|
390
390
|
const fullCount = Object.keys(fullStyles).length;
|
|
391
391
|
|
|
392
392
|
// Calculate diff
|
|
393
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
393
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
394
394
|
let diffCount = 0;
|
|
395
395
|
for (const key in fullStyles) {
|
|
396
396
|
if (fullStyles[key] !== lightStyles[key]) {
|
|
@@ -646,8 +646,8 @@ describe("ThemeProvider", () => {
|
|
|
646
646
|
const lightTheme = themeFromPalette(palette, "light");
|
|
647
647
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
648
648
|
|
|
649
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
650
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
649
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
650
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
651
651
|
let expectedDiffCount = 0;
|
|
652
652
|
for (const key in darkStyles) {
|
|
653
653
|
if (darkStyles[key] !== lightStyles[key]) {
|
|
@@ -690,8 +690,8 @@ describe("ThemeProvider", () => {
|
|
|
690
690
|
const lightTheme = themeFromPalette(palette, "light");
|
|
691
691
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
692
692
|
|
|
693
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
694
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
693
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
694
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
695
695
|
let expectedDiffCount = 0;
|
|
696
696
|
for (const key in darkStyles) {
|
|
697
697
|
if (darkStyles[key] !== lightStyles[key]) {
|
|
@@ -744,8 +744,8 @@ describe("ThemeProvider", () => {
|
|
|
744
744
|
const lightTheme = themeFromPalette(palette, "light");
|
|
745
745
|
const darkTheme = themeFromPalette(palette, "dark");
|
|
746
746
|
|
|
747
|
-
const lightStyles = stylesFromTheme(lightTheme
|
|
748
|
-
const darkStyles = stylesFromTheme(darkTheme
|
|
747
|
+
const lightStyles = stylesFromTheme(lightTheme);
|
|
748
|
+
const darkStyles = stylesFromTheme(darkTheme);
|
|
749
749
|
let expectedDiffCount = 0;
|
|
750
750
|
for (const key in darkStyles) {
|
|
751
751
|
if (darkStyles[key] !== lightStyles[key]) {
|
|
@@ -776,7 +776,7 @@ describe("ThemeProvider", () => {
|
|
|
776
776
|
|
|
777
777
|
function StylesCheck() {
|
|
778
778
|
const styles = useThemeStyles();
|
|
779
|
-
const expected = stylesFromTheme(darkTheme
|
|
779
|
+
const expected = stylesFromTheme(darkTheme);
|
|
780
780
|
const match = Object.keys(expected).every((k) => styles[k] === expected[k]);
|
|
781
781
|
return <div data-testid="styles-match" data-match={String(match)} />;
|
|
782
782
|
}
|
package/src/theme-provider.tsx
CHANGED
|
@@ -12,7 +12,7 @@ import {selectPalette} from "./palette-generator";
|
|
|
12
12
|
import type {ThemeMode, ThemePreference} from "./theme-settings";
|
|
13
13
|
import {subscribeOnThemeModeChange, subscribeOnThemePreferenceChange, useWarmPreference} from "./theme-settings";
|
|
14
14
|
import {locateThemeBundle} from "./theme-styles";
|
|
15
|
-
import {neutralStyles,
|
|
15
|
+
import {neutralStyles, warmStyles} from "./theming.generated";
|
|
16
16
|
|
|
17
17
|
const darkClassName = "dark-theme";
|
|
18
18
|
const warmClassName = "warm-palette";
|
|
@@ -122,7 +122,7 @@ export function ThemeProvider({
|
|
|
122
122
|
const theme = themeOverride ?? (portal ? parentTheme : themeFromPalette(palette, mode));
|
|
123
123
|
|
|
124
124
|
const parentStyles = useContext(portal ? RootThemeStylesContext : ThemeStylesContext);
|
|
125
|
-
const styles = stylesFromTheme(theme
|
|
125
|
+
const styles = stylesFromTheme(theme);
|
|
126
126
|
const stylesDiff = useMemo(() => {
|
|
127
127
|
if (styles === parentStyles) {
|
|
128
128
|
return undefined;
|
|
@@ -206,11 +206,7 @@ export function RootThemeProvider({
|
|
|
206
206
|
} = locateThemeBundle(warm);
|
|
207
207
|
const styleBundle = warm ? warmStyles : neutralStyles;
|
|
208
208
|
const cssThemeColors = dark ? darkThemeColors : lightThemeColors;
|
|
209
|
-
|
|
210
|
-
if (process.env.NODE_ENV === "development") {
|
|
211
|
-
// In dev build, we use empty styles as a reference to force all vars inline in top themeproviders — avoids stale Linaria/babel cache.
|
|
212
|
-
cssThemeStyles = {};
|
|
213
|
-
}
|
|
209
|
+
const cssThemeStyles: Styles = dark ? styleBundle.dark : styleBundle.light;
|
|
214
210
|
res = <ThemeStylesContext.Provider value={cssThemeStyles}>{res}</ThemeStylesContext.Provider>;
|
|
215
211
|
res = <RootThemeStylesContext.Provider value={cssThemeStyles}>{res}</RootThemeStylesContext.Provider>;
|
|
216
212
|
res = <ThemeContext.Provider value={cssThemeColors}>{res}</ThemeContext.Provider>;
|