@nordmanai/nif 0.0.0-stage → 0.2.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/README.md +79 -2
- package/bin/nif.mjs +196 -0
- package/dist/index.d.ts +124 -0
- package/dist/index.js +12961 -0
- package/dist/styles.css +2 -0
- package/dist/tokens.css +72 -0
- package/dist/ui/components/nm-ai/nm-ai.d.ts +222 -0
- package/dist/ui/components/nm-avatar/nm-avatar.d.ts +12 -0
- package/dist/ui/components/nm-bar-overflow/nm-bar-overflow.d.ts +15 -0
- package/dist/ui/components/nm-bar-overflow/use-bar-overflow.d.ts +7 -0
- package/dist/ui/components/nm-brand-logo/nm-brand-logo.d.ts +10 -0
- package/dist/ui/components/nm-breadcrumb/nm-breadcrumb.d.ts +11 -0
- package/dist/ui/components/nm-button/nm-button.d.ts +19 -0
- package/dist/ui/components/nm-button-group/nm-button-group.d.ts +17 -0
- package/dist/ui/components/nm-calendar/nm-calendar.d.ts +3 -0
- package/dist/ui/components/nm-card/nm-card.d.ts +34 -0
- package/dist/ui/components/nm-chatbox/nm-chatbox-icon.d.ts +7 -0
- package/dist/ui/components/nm-chatbox/nm-chatbox.d.ts +19 -0
- package/dist/ui/components/nm-checkbox/nm-checkbox.d.ts +2 -0
- package/dist/ui/components/nm-chip/nm-chip.d.ts +38 -0
- package/dist/ui/components/nm-code-block/nm-code-block.d.ts +55 -0
- package/dist/ui/components/nm-collection/nm-collection-bar.d.ts +16 -0
- package/dist/ui/components/nm-collection/nm-collection-grid.d.ts +9 -0
- package/dist/ui/components/nm-collection/nm-collection-query.d.ts +18 -0
- package/dist/ui/components/nm-collection/nm-collection-row-menu.d.ts +7 -0
- package/dist/ui/components/nm-collection/nm-collection-table.d.ts +13 -0
- package/dist/ui/components/nm-collection/nm-collection-tile-actions.d.ts +7 -0
- package/dist/ui/components/nm-collection/nm-collection-title.d.ts +10 -0
- package/dist/ui/components/nm-collection/use-collection-scroll-reveal.d.ts +3 -0
- package/dist/ui/components/nm-color-picker/nm-color-picker.d.ts +15 -0
- package/dist/ui/components/nm-combobox/nm-combobox.d.ts +26 -0
- package/dist/ui/components/nm-command/nm-command.d.ts +37 -0
- package/dist/ui/components/nm-composer/nm-composer.d.ts +33 -0
- package/dist/ui/components/nm-context-menu/nm-context-menu.d.ts +9 -0
- package/dist/ui/components/nm-date-picker/nm-date-picker.d.ts +35 -0
- package/dist/ui/components/nm-dialog/nm-dialog.d.ts +13 -0
- package/dist/ui/components/nm-dropdown/nm-dropdown-item.d.ts +26 -0
- package/dist/ui/components/nm-dropdown/nm-dropdown-options.d.ts +12 -0
- package/dist/ui/components/nm-dropdown/nm-dropdown-panel.d.ts +16 -0
- package/dist/ui/components/nm-dropdown/nm-dropdown-placement.d.ts +55 -0
- package/dist/ui/components/nm-dropdown/nm-dropdown.d.ts +31 -0
- package/dist/ui/components/nm-dropdown-menu/nm-dropdown-menu.d.ts +30 -0
- package/dist/ui/components/nm-field/nm-field.d.ts +52 -0
- package/dist/ui/components/nm-form-field/nm-form-field.d.ts +18 -0
- package/dist/ui/components/nm-gallery/nm-gallery.d.ts +8 -0
- package/dist/ui/components/nm-hover-card/nm-hover-card.d.ts +5 -0
- package/dist/ui/components/nm-icon/nm-icon.d.ts +7 -0
- package/dist/ui/components/nm-icon/nm-lucide.d.ts +7 -0
- package/dist/ui/components/nm-icon-border/nm-icon-border.d.ts +21 -0
- package/dist/ui/components/nm-input/nm-input.d.ts +5 -0
- package/dist/ui/components/nm-input-group/nm-input-group.d.ts +9 -0
- package/dist/ui/components/nm-label/nm-label.d.ts +2 -0
- package/dist/ui/components/nm-list-item/nm-list-item.d.ts +23 -0
- package/dist/ui/components/nm-menubar/nm-menubar.d.ts +9 -0
- package/dist/ui/components/nm-message/nm-message-actions.d.ts +7 -0
- package/dist/ui/components/nm-message/nm-message-meta.d.ts +10 -0
- package/dist/ui/components/nm-message/nm-text-shimmer.d.ts +4 -0
- package/dist/ui/components/nm-message/nm-trace.d.ts +58 -0
- package/dist/ui/components/nm-modal/nm-modal.d.ts +35 -0
- package/dist/ui/components/nm-native-select/nm-native-select.d.ts +5 -0
- package/dist/ui/components/nm-panel/nm-panel.d.ts +14 -0
- package/dist/ui/components/nm-panel-bar/nm-panel-bar.d.ts +17 -0
- package/dist/ui/components/nm-popover/nm-popover.d.ts +8 -0
- package/dist/ui/components/nm-progress/nm-progress.d.ts +3 -0
- package/dist/ui/components/nm-prose/nm-prose.d.ts +6 -0
- package/dist/ui/components/nm-questionnaire/nm-questionnaire.d.ts +17 -0
- package/dist/ui/components/nm-radio-group/nm-radio-group.d.ts +4 -0
- package/dist/ui/components/nm-rail-icon/nm-rail-icon.d.ts +6 -0
- package/dist/ui/components/nm-resize-handle/nm-resize-handle.d.ts +18 -0
- package/dist/ui/components/nm-segmented/nm-segmented.d.ts +20 -0
- package/dist/ui/components/nm-select/nm-select.d.ts +22 -0
- package/dist/ui/components/nm-separator/nm-separator.d.ts +2 -0
- package/dist/ui/components/nm-side-panel/nm-side-panel.d.ts +33 -0
- package/dist/ui/components/nm-slider/nm-slider.d.ts +6 -0
- package/dist/ui/components/nm-small-icon-button/nm-small-icon-button.d.ts +21 -0
- package/dist/ui/components/nm-status-bar/nm-status-bar.d.ts +8 -0
- package/dist/ui/components/nm-switch/nm-switch.d.ts +2 -0
- package/dist/ui/components/nm-table/nm-table.d.ts +38 -0
- package/dist/ui/components/nm-tabs/nm-tabs.d.ts +9 -0
- package/dist/ui/components/nm-textarea/nm-textarea.d.ts +2 -0
- package/dist/ui/components/nm-toggle/nm-toggle.d.ts +9 -0
- package/dist/ui/components/nm-toolbar/nm-toolbar.d.ts +21 -0
- package/dist/ui/components/nm-tooltip/nm-tooltip.d.ts +5 -0
- package/dist/ui/components/nm-top-bar/nm-top-bar.d.ts +12 -0
- package/dist/ui/components/nordman-icon-button/nordman-icon-button.d.ts +29 -0
- package/dist/ui/components/nordman-login/nordman-login.d.ts +36 -0
- package/dist/ui/components/nordman-login-field/nordman-login-field.d.ts +13 -0
- package/dist/ui/components/nordman-login-forgot/nordman-login-forgot.d.ts +9 -0
- package/dist/ui/components/nordman-login-google/nordman-login-google.d.ts +6 -0
- package/dist/ui/components/nordman-login-hero/nordman-login-hero.d.ts +6 -0
- package/dist/ui/components/nordman-login-register/nordman-login-register.d.ts +11 -0
- package/dist/ui/components/nordman-login-reset/nordman-login-reset.d.ts +9 -0
- package/dist/ui/components/nordman-login-reveal/nordman-login-reveal.d.ts +6 -0
- package/dist/ui/components/nordman-login-sign-in/nordman-login-sign-in.d.ts +11 -0
- package/dist/ui/components/nordman-toggle/nordman-toggle.d.ts +12 -0
- package/dist/ui/config/nm-ai.d.ts +44 -0
- package/dist/ui/config/nm-app-panel.d.ts +36 -0
- package/dist/ui/config/nm-appearance.d.ts +100 -0
- package/dist/ui/config/nm-bar-overflow.d.ts +9 -0
- package/dist/ui/config/nm-button.d.ts +31 -0
- package/dist/ui/config/nm-chatbox-icons.d.ts +42 -0
- package/dist/ui/config/nm-chatbox.d.ts +40 -0
- package/dist/ui/config/nm-collection.d.ts +88 -0
- package/dist/ui/config/nm-composer.d.ts +42 -0
- package/dist/ui/config/nm-dropdown.d.ts +56 -0
- package/dist/ui/config/nm-fade.d.ts +6 -0
- package/dist/ui/config/nm-field.d.ts +38 -0
- package/dist/ui/config/nm-header-icons.d.ts +15 -0
- package/dist/ui/config/nm-icon-border.d.ts +3 -0
- package/dist/ui/config/nm-icon-button.d.ts +26 -0
- package/dist/ui/config/nm-icons.d.ts +371 -0
- package/dist/ui/config/nm-list-item.d.ts +14 -0
- package/dist/ui/config/nm-message.d.ts +87 -0
- package/dist/ui/config/nm-modal.d.ts +67 -0
- package/dist/ui/config/nm-panel-bar.d.ts +9 -0
- package/dist/ui/config/nm-questionnaire.d.ts +57 -0
- package/dist/ui/config/nm-radius.d.ts +49 -0
- package/dist/ui/config/nm-rail-icons.d.ts +14 -0
- package/dist/ui/config/nm-rail.d.ts +5 -0
- package/dist/ui/config/nm-segmented.d.ts +17 -0
- package/dist/ui/config/nm-side-panel.d.ts +33 -0
- package/dist/ui/config/nm-site-palette.d.ts +30 -0
- package/dist/ui/config/nm-small-icon-button.d.ts +12 -0
- package/dist/ui/config/nm-tabs.d.ts +8 -0
- package/dist/ui/config/nm-top-bar.d.ts +4 -0
- package/dist/ui/config/nordman-chrome.d.ts +12 -0
- package/dist/ui/config/nordman-login.d.ts +23 -0
- package/dist/ui/content/nm-modal.d.ts +1 -0
- package/dist/ui/content/nordman-login.d.ts +38 -0
- package/dist/ui/kit-logger.d.ts +1 -0
- package/dist/ui/lib/appearance/appearanceState.d.ts +28 -0
- package/dist/ui/lib/appearance/applyAppearance.d.ts +5 -0
- package/dist/ui/lib/appearance/cloudOrbAppearance.d.ts +4 -0
- package/dist/ui/lib/appearance/color.d.ts +13 -0
- package/dist/ui/lib/appearance/deriveTokens.d.ts +6 -0
- package/dist/ui/lib/appearance/index.d.ts +6 -0
- package/dist/ui/lib/appearance/markTokens.d.ts +2 -0
- package/dist/ui/lib/appearance/readLayoutMetrics.d.ts +4 -0
- package/dist/ui/lib/bar-overflow.d.ts +13 -0
- package/dist/ui/lib/logger.d.ts +8 -0
- package/dist/ui/lib/menu-motion.d.ts +72 -0
- package/dist/ui/lib/nm-class.d.ts +2 -0
- package/dist/ui/lib/nordman-ui-locale.d.ts +9 -0
- package/interface/app-panel/code.svg +5 -0
- package/interface/app-panel/console.svg +5 -0
- package/interface/app-panel/copy.svg +5 -0
- package/interface/app-panel/ellipsis.svg +7 -0
- package/interface/app-panel/message.svg +5 -0
- package/interface/app-panel/network.svg +10 -0
- package/interface/app-panel/play.svg +5 -0
- package/interface/app-panel/plus.svg +5 -0
- package/interface/chatbox/app.svg +5 -0
- package/interface/chatbox/audio-lines.svg +5 -0
- package/interface/chatbox/check.svg +5 -0
- package/interface/chatbox/globe.svg +5 -0
- package/interface/chatbox/integration.svg +5 -0
- package/interface/chatbox/mic.svg +5 -0
- package/interface/chatbox/paperclip.svg +5 -0
- package/interface/chatbox/pointer.svg +5 -0
- package/interface/chatbox/send.svg +5 -0
- package/interface/chatbox/settings.svg +5 -0
- package/interface/chatbox/spreadsheet.svg +5 -0
- package/interface/chatbox/x.svg +5 -0
- package/interface/collection/audio.svg +5 -0
- package/interface/collection/download.svg +5 -0
- package/interface/collection/expand.svg +5 -0
- package/interface/collection/grid.svg +10 -0
- package/interface/collection/image.svg +5 -0
- package/interface/collection/spreadsheet.svg +5 -0
- package/interface/collection/video.svg +5 -0
- package/interface/header/app.svg +5 -0
- package/interface/header/bot.svg +5 -0
- package/interface/header/chat.svg +10 -0
- package/interface/header/folder.svg +5 -0
- package/interface/header/layers.svg +10 -0
- package/interface/header/panel.svg +5 -0
- package/interface/header/play.svg +3 -0
- package/interface/header/schedule.svg +8 -0
- package/interface/header/search.svg +5 -0
- package/interface/header/settings.svg +5 -0
- package/interface/header/users.svg +5 -0
- package/interface/message/chevron.svg +5 -0
- package/interface/message/copy.svg +5 -0
- package/interface/message/fork.svg +5 -0
- package/interface/message/refresh.svg +5 -0
- package/interface/message/volume.svg +5 -0
- package/interface/rail/app.svg +5 -0
- package/interface/rail/bot.svg +5 -0
- package/interface/rail/chats.svg +5 -0
- package/interface/rail/folder.svg +5 -0
- package/interface/rail/library.svg +5 -0
- package/interface/rail/plus-sm.svg +5 -0
- package/interface/rail/plus.svg +5 -0
- package/interface/rail/search.svg +5 -0
- package/interface/rail/settings.svg +8 -0
- package/interface/rail/spreadsheet.svg +5 -0
- package/package.json +79 -4
- package/registry/index.json +1634 -0
- package/registry/tokens.css +72 -0
- package/registry/ui/components/nm-ai/nm-ai.css +358 -0
- package/registry/ui/components/nm-ai/nm-ai.tsx +632 -0
- package/registry/ui/components/nm-app-panel/nm-app-panel.css +169 -0
- package/registry/ui/components/nm-ask/nm-ask.css +277 -0
- package/registry/ui/components/nm-avatar/nm-avatar.css +85 -0
- package/registry/ui/components/nm-avatar/nm-avatar.tsx +30 -0
- package/registry/ui/components/nm-bar-overflow/nm-bar-overflow.css +43 -0
- package/registry/ui/components/nm-bar-overflow/nm-bar-overflow.tsx +61 -0
- package/registry/ui/components/nm-bar-overflow/use-bar-overflow.ts +92 -0
- package/registry/ui/components/nm-brand-logo/nm-brand-logo.css +20 -0
- package/registry/ui/components/nm-brand-logo/nm-brand-logo.tsx +21 -0
- package/registry/ui/components/nm-breadcrumb/nm-breadcrumb.css +57 -0
- package/registry/ui/components/nm-breadcrumb/nm-breadcrumb.tsx +42 -0
- package/registry/ui/components/nm-button/nm-button.css +110 -0
- package/registry/ui/components/nm-button/nm-button.tsx +58 -0
- package/registry/ui/components/nm-button-group/nm-button-group.css +87 -0
- package/registry/ui/components/nm-button-group/nm-button-group.tsx +32 -0
- package/registry/ui/components/nm-calendar/nm-calendar.css +178 -0
- package/registry/ui/components/nm-calendar/nm-calendar.tsx +43 -0
- package/registry/ui/components/nm-card/nm-card.css +130 -0
- package/registry/ui/components/nm-card/nm-card.tsx +83 -0
- package/registry/ui/components/nm-chatbox/nm-chatbox-icon.tsx +39 -0
- package/registry/ui/components/nm-chatbox/nm-chatbox.css +682 -0
- package/registry/ui/components/nm-chatbox/nm-chatbox.tsx +101 -0
- package/registry/ui/components/nm-checkbox/nm-checkbox.css +61 -0
- package/registry/ui/components/nm-checkbox/nm-checkbox.tsx +14 -0
- package/registry/ui/components/nm-chip/nm-chip.css +112 -0
- package/registry/ui/components/nm-chip/nm-chip.tsx +86 -0
- package/registry/ui/components/nm-code-block/nm-code-block.css +240 -0
- package/registry/ui/components/nm-code-block/nm-code-block.tsx +196 -0
- package/registry/ui/components/nm-collection/nm-collection-bar.tsx +65 -0
- package/registry/ui/components/nm-collection/nm-collection-grid.tsx +69 -0
- package/registry/ui/components/nm-collection/nm-collection-query.tsx +99 -0
- package/registry/ui/components/nm-collection/nm-collection-row-menu.tsx +55 -0
- package/registry/ui/components/nm-collection/nm-collection-table.tsx +99 -0
- package/registry/ui/components/nm-collection/nm-collection-tile-actions.tsx +50 -0
- package/registry/ui/components/nm-collection/nm-collection-title.tsx +25 -0
- package/registry/ui/components/nm-collection/nm-collection.css +353 -0
- package/registry/ui/components/nm-collection/use-collection-scroll-reveal.ts +38 -0
- package/registry/ui/components/nm-color-picker/nm-color-picker.css +67 -0
- package/registry/ui/components/nm-color-picker/nm-color-picker.tsx +79 -0
- package/registry/ui/components/nm-combobox/nm-combobox.css +72 -0
- package/registry/ui/components/nm-combobox/nm-combobox.tsx +80 -0
- package/registry/ui/components/nm-command/nm-command.css +190 -0
- package/registry/ui/components/nm-command/nm-command.tsx +125 -0
- package/registry/ui/components/nm-composer/nm-composer.css +178 -0
- package/registry/ui/components/nm-composer/nm-composer.tsx +151 -0
- package/registry/ui/components/nm-context-menu/nm-context-menu.tsx +25 -0
- package/registry/ui/components/nm-date-picker/nm-date-picker.css +140 -0
- package/registry/ui/components/nm-date-picker/nm-date-picker.tsx +153 -0
- package/registry/ui/components/nm-dialog/nm-dialog.css +84 -0
- package/registry/ui/components/nm-dialog/nm-dialog.tsx +40 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown-item.ts +68 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown-options.tsx +242 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown-panel.tsx +171 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown-placement.ts +157 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown.css +312 -0
- package/registry/ui/components/nm-dropdown/nm-dropdown.tsx +412 -0
- package/registry/ui/components/nm-dropdown-menu/nm-dropdown-menu.css +145 -0
- package/registry/ui/components/nm-dropdown-menu/nm-dropdown-menu.tsx +118 -0
- package/registry/ui/components/nm-field/nm-field.css +356 -0
- package/registry/ui/components/nm-field/nm-field.tsx +355 -0
- package/registry/ui/components/nm-form-field/nm-form-field.css +103 -0
- package/registry/ui/components/nm-form-field/nm-form-field.tsx +71 -0
- package/registry/ui/components/nm-gallery/nm-gallery.css +66 -0
- package/registry/ui/components/nm-gallery/nm-gallery.tsx +31 -0
- package/registry/ui/components/nm-hover-card/nm-hover-card.css +26 -0
- package/registry/ui/components/nm-hover-card/nm-hover-card.tsx +28 -0
- package/registry/ui/components/nm-icon/nm-icon.css +6 -0
- package/registry/ui/components/nm-icon/nm-icon.tsx +69 -0
- package/registry/ui/components/nm-icon/nm-lucide.tsx +180 -0
- package/registry/ui/components/nm-icon-border/nm-icon-border.tsx +56 -0
- package/registry/ui/components/nm-input/nm-input.css +75 -0
- package/registry/ui/components/nm-input/nm-input.tsx +7 -0
- package/registry/ui/components/nm-input-group/nm-input-group.css +66 -0
- package/registry/ui/components/nm-input-group/nm-input-group.tsx +20 -0
- package/registry/ui/components/nm-label/nm-label.css +11 -0
- package/registry/ui/components/nm-label/nm-label.tsx +6 -0
- package/registry/ui/components/nm-list-item/nm-list-item.css +177 -0
- package/registry/ui/components/nm-list-item/nm-list-item.tsx +112 -0
- package/registry/ui/components/nm-menubar/nm-menubar.css +32 -0
- package/registry/ui/components/nm-menubar/nm-menubar.tsx +19 -0
- package/registry/ui/components/nm-message/nm-message-actions.tsx +24 -0
- package/registry/ui/components/nm-message/nm-message-meta.tsx +49 -0
- package/registry/ui/components/nm-message/nm-message.css +686 -0
- package/registry/ui/components/nm-message/nm-text-shimmer.tsx +6 -0
- package/registry/ui/components/nm-message/nm-trace.tsx +219 -0
- package/registry/ui/components/nm-modal/nm-modal.css +763 -0
- package/registry/ui/components/nm-modal/nm-modal.tsx +497 -0
- package/registry/ui/components/nm-native-select/nm-native-select.css +47 -0
- package/registry/ui/components/nm-native-select/nm-native-select.tsx +23 -0
- package/registry/ui/components/nm-panel/nm-panel.css +73 -0
- package/registry/ui/components/nm-panel/nm-panel.tsx +35 -0
- package/registry/ui/components/nm-panel-bar/nm-panel-bar.css +20 -0
- package/registry/ui/components/nm-panel-bar/nm-panel-bar.tsx +48 -0
- package/registry/ui/components/nm-popover/nm-popover.css +43 -0
- package/registry/ui/components/nm-popover/nm-popover.tsx +40 -0
- package/registry/ui/components/nm-progress/nm-progress.css +21 -0
- package/registry/ui/components/nm-progress/nm-progress.tsx +14 -0
- package/registry/ui/components/nm-prose/nm-prose.css +81 -0
- package/registry/ui/components/nm-prose/nm-prose.tsx +10 -0
- package/registry/ui/components/nm-questionnaire/nm-questionnaire.css +182 -0
- package/registry/ui/components/nm-questionnaire/nm-questionnaire.tsx +221 -0
- package/registry/ui/components/nm-radio-group/nm-radio-group.css +48 -0
- package/registry/ui/components/nm-radio-group/nm-radio-group.tsx +15 -0
- package/registry/ui/components/nm-rail-icon/nm-rail-icon.css +6 -0
- package/registry/ui/components/nm-rail-icon/nm-rail-icon.tsx +28 -0
- package/registry/ui/components/nm-resize-handle/nm-resize-handle.css +45 -0
- package/registry/ui/components/nm-resize-handle/nm-resize-handle.tsx +102 -0
- package/registry/ui/components/nm-segmented/nm-segmented.css +104 -0
- package/registry/ui/components/nm-segmented/nm-segmented.tsx +77 -0
- package/registry/ui/components/nm-select/nm-select.css +78 -0
- package/registry/ui/components/nm-select/nm-select.tsx +64 -0
- package/registry/ui/components/nm-separator/nm-separator.css +14 -0
- package/registry/ui/components/nm-separator/nm-separator.tsx +6 -0
- package/registry/ui/components/nm-side-panel/nm-side-panel.css +93 -0
- package/registry/ui/components/nm-side-panel/nm-side-panel.tsx +86 -0
- package/registry/ui/components/nm-slider/nm-slider.css +53 -0
- package/registry/ui/components/nm-slider/nm-slider.tsx +40 -0
- package/registry/ui/components/nm-small-icon-button/nm-small-icon-button.tsx +66 -0
- package/registry/ui/components/nm-status-bar/nm-status-bar.css +50 -0
- package/registry/ui/components/nm-status-bar/nm-status-bar.tsx +28 -0
- package/registry/ui/components/nm-switch/nm-switch.css +45 -0
- package/registry/ui/components/nm-switch/nm-switch.tsx +10 -0
- package/registry/ui/components/nm-table/nm-table.css +155 -0
- package/registry/ui/components/nm-table/nm-table.tsx +95 -0
- package/registry/ui/components/nm-tabs/nm-tabs.css +28 -0
- package/registry/ui/components/nm-tabs/nm-tabs.tsx +32 -0
- package/registry/ui/components/nm-textarea/nm-textarea.css +41 -0
- package/registry/ui/components/nm-textarea/nm-textarea.tsx +6 -0
- package/registry/ui/components/nm-toggle/nm-toggle.css +55 -0
- package/registry/ui/components/nm-toggle/nm-toggle.tsx +16 -0
- package/registry/ui/components/nm-toolbar/nm-toolbar.css +42 -0
- package/registry/ui/components/nm-toolbar/nm-toolbar.tsx +54 -0
- package/registry/ui/components/nm-tooltip/nm-tooltip.css +37 -0
- package/registry/ui/components/nm-tooltip/nm-tooltip.tsx +35 -0
- package/registry/ui/components/nm-top-bar/nm-top-bar.css +29 -0
- package/registry/ui/components/nm-top-bar/nm-top-bar.tsx +34 -0
- package/registry/ui/components/nordman-icon-button/nordman-icon-button.css +119 -0
- package/registry/ui/components/nordman-icon-button/nordman-icon-button.tsx +185 -0
- package/registry/ui/components/nordman-login/nordman-login.css +195 -0
- package/registry/ui/components/nordman-login/nordman-login.tsx +136 -0
- package/registry/ui/components/nordman-login-field/nordman-login-field.tsx +55 -0
- package/registry/ui/components/nordman-login-forgot/nordman-login-forgot.tsx +56 -0
- package/registry/ui/components/nordman-login-google/nordman-login-google.tsx +28 -0
- package/registry/ui/components/nordman-login-hero/nordman-login-hero.tsx +38 -0
- package/registry/ui/components/nordman-login-register/nordman-login-register.tsx +70 -0
- package/registry/ui/components/nordman-login-reset/nordman-login-reset.tsx +71 -0
- package/registry/ui/components/nordman-login-reveal/nordman-login-reveal.tsx +41 -0
- package/registry/ui/components/nordman-login-sign-in/nordman-login-sign-in.tsx +69 -0
- package/registry/ui/components/nordman-toggle/nordman-toggle.css +28 -0
- package/registry/ui/components/nordman-toggle/nordman-toggle.tsx +35 -0
- package/registry/ui/config/nm-ai.ts +59 -0
- package/registry/ui/config/nm-appearance.ts +275 -0
- package/registry/ui/config/nm-bar-overflow.ts +10 -0
- package/registry/ui/config/nm-button.ts +38 -0
- package/registry/ui/config/nm-chatbox-icons.ts +67 -0
- package/registry/ui/config/nm-chatbox.ts +42 -0
- package/registry/ui/config/nm-collection.ts +101 -0
- package/registry/ui/config/nm-composer.ts +39 -0
- package/registry/ui/config/nm-dropdown.ts +62 -0
- package/registry/ui/config/nm-field.ts +43 -0
- package/registry/ui/config/nm-icon-button.ts +35 -0
- package/registry/ui/config/nm-icons.ts +417 -0
- package/registry/ui/config/nm-list-item.ts +14 -0
- package/registry/ui/config/nm-message.ts +106 -0
- package/registry/ui/config/nm-modal.ts +76 -0
- package/registry/ui/config/nm-panel-bar.ts +11 -0
- package/registry/ui/config/nm-questionnaire.ts +53 -0
- package/registry/ui/config/nm-radius.ts +56 -0
- package/registry/ui/config/nm-rail-icons.ts +27 -0
- package/registry/ui/config/nm-segmented.ts +19 -0
- package/registry/ui/config/nm-side-panel.ts +16 -0
- package/registry/ui/config/nm-site-palette.ts +30 -0
- package/registry/ui/config/nm-small-icon-button.ts +17 -0
- package/registry/ui/config/nm-tabs.ts +9 -0
- package/registry/ui/config/nm-top-bar.ts +4 -0
- package/registry/ui/config/nordman-chrome.ts +14 -0
- package/registry/ui/config/nordman-login.ts +28 -0
- package/registry/ui/content/nm-modal.ts +5 -0
- package/registry/ui/content/nordman-login.ts +85 -0
- package/registry/ui/kit-logger.ts +1 -0
- package/registry/ui/lib/appearance/appearanceState.ts +240 -0
- package/registry/ui/lib/appearance/applyAppearance.ts +36 -0
- package/registry/ui/lib/appearance/cloudOrbAppearance.ts +36 -0
- package/registry/ui/lib/appearance/color.ts +96 -0
- package/registry/ui/lib/appearance/deriveTokens.ts +218 -0
- package/registry/ui/lib/appearance/index.ts +6 -0
- package/registry/ui/lib/appearance/markTokens.ts +49 -0
- package/registry/ui/lib/appearance/readLayoutMetrics.ts +28 -0
- package/registry/ui/lib/bar-overflow.ts +41 -0
- package/registry/ui/lib/logger.ts +53 -0
- package/registry/ui/lib/menu-motion.ts +187 -0
- package/registry/ui/lib/nm-class.ts +4 -0
- package/registry/ui/lib/nordman-ui-locale.ts +43 -0
- package/registry/ui/styles/interface-theme.css +196 -0
- package/registry/ui/styles/light-appearance.css +72 -0
- package/registry/ui/styles/tokens.css +424 -0
- package/registry/ui/styles/utilities.css +12 -0
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import { NM_ICONS, type NmIconId, type NmIconSpec } from '../../config/nm-icons.ts';
|
|
3
|
+
import { hasNmLucide, NmLucide } from './nm-lucide.tsx';
|
|
4
|
+
import { createLogger } from '../../kit-logger.ts';
|
|
5
|
+
|
|
6
|
+
const logger = createLogger('interface-nm-icon');
|
|
7
|
+
|
|
8
|
+
export type NmIconProps = {
|
|
9
|
+
id: NmIconId;
|
|
10
|
+
className?: string;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
function iconStrokes(path: string | readonly string[] | undefined): string[] {
|
|
14
|
+
if (path == null) {
|
|
15
|
+
return [];
|
|
16
|
+
}
|
|
17
|
+
if (typeof path === 'string') {
|
|
18
|
+
return [path];
|
|
19
|
+
}
|
|
20
|
+
return [...path];
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export function NmIcon(props: NmIconProps): ReactNode {
|
|
24
|
+
if (hasNmLucide(props.id)) {
|
|
25
|
+
logger.debug('render', props.id);
|
|
26
|
+
return <NmLucide id={props.id} className={props.className} />;
|
|
27
|
+
}
|
|
28
|
+
const spec: NmIconSpec | undefined = NM_ICONS[props.id as keyof typeof NM_ICONS];
|
|
29
|
+
if (!spec) {
|
|
30
|
+
logger.warn('render', 'unknown icon', { id: props.id });
|
|
31
|
+
return null;
|
|
32
|
+
}
|
|
33
|
+
const strokes = iconStrokes(spec.path);
|
|
34
|
+
logger.debug('render', props.id);
|
|
35
|
+
return (
|
|
36
|
+
<svg
|
|
37
|
+
className={props.className == null ? 'nm-icon' : `nm-icon ${props.className}`}
|
|
38
|
+
data-icon={props.id}
|
|
39
|
+
viewBox={spec.viewBox}
|
|
40
|
+
fill="none"
|
|
41
|
+
aria-hidden="true"
|
|
42
|
+
focusable="false"
|
|
43
|
+
>
|
|
44
|
+
{spec.fill ? <path d={spec.fill} fill="currentColor" /> : null}
|
|
45
|
+
{strokes.map((d) => (
|
|
46
|
+
<path
|
|
47
|
+
key={d}
|
|
48
|
+
d={d}
|
|
49
|
+
stroke="currentColor"
|
|
50
|
+
strokeWidth="2"
|
|
51
|
+
strokeLinecap="round"
|
|
52
|
+
strokeLinejoin="round"
|
|
53
|
+
/>
|
|
54
|
+
))}
|
|
55
|
+
{spec.circles?.map((circle) => (
|
|
56
|
+
<circle
|
|
57
|
+
key={`${circle.cx}-${circle.cy}`}
|
|
58
|
+
cx={circle.cx}
|
|
59
|
+
cy={circle.cy}
|
|
60
|
+
r={circle.r}
|
|
61
|
+
stroke="currentColor"
|
|
62
|
+
strokeWidth="2"
|
|
63
|
+
strokeLinecap="round"
|
|
64
|
+
strokeLinejoin="round"
|
|
65
|
+
/>
|
|
66
|
+
))}
|
|
67
|
+
</svg>
|
|
68
|
+
);
|
|
69
|
+
}
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import {
|
|
2
|
+
AppWindowMac,
|
|
3
|
+
ArrowLeft,
|
|
4
|
+
ArrowRight,
|
|
5
|
+
PanelLeft,
|
|
6
|
+
Rows2,
|
|
7
|
+
ArrowUp,
|
|
8
|
+
AudioLines,
|
|
9
|
+
Bot,
|
|
10
|
+
Box,
|
|
11
|
+
Brain,
|
|
12
|
+
Building,
|
|
13
|
+
Cable,
|
|
14
|
+
Calendar,
|
|
15
|
+
Check,
|
|
16
|
+
CircleCheck,
|
|
17
|
+
Clock,
|
|
18
|
+
Gauge,
|
|
19
|
+
Minus,
|
|
20
|
+
ChevronDown,
|
|
21
|
+
Code,
|
|
22
|
+
Copy,
|
|
23
|
+
Ellipsis,
|
|
24
|
+
File,
|
|
25
|
+
FileCode2,
|
|
26
|
+
FileText,
|
|
27
|
+
Server,
|
|
28
|
+
SquareDashedBottomCode,
|
|
29
|
+
SquareDashedMousePointer,
|
|
30
|
+
Folder,
|
|
31
|
+
Github,
|
|
32
|
+
Globe,
|
|
33
|
+
HardDrive,
|
|
34
|
+
Headphones,
|
|
35
|
+
Image,
|
|
36
|
+
ImagePlus,
|
|
37
|
+
LayoutGrid,
|
|
38
|
+
LibraryBig,
|
|
39
|
+
ListFilter,
|
|
40
|
+
LoaderCircle,
|
|
41
|
+
Mail,
|
|
42
|
+
Maximize2,
|
|
43
|
+
Menu,
|
|
44
|
+
RotateCcw,
|
|
45
|
+
MessageCircle,
|
|
46
|
+
MessageCircleDashed,
|
|
47
|
+
Mic,
|
|
48
|
+
MicOff,
|
|
49
|
+
MonitorStop,
|
|
50
|
+
Moon,
|
|
51
|
+
Music,
|
|
52
|
+
PanelRight,
|
|
53
|
+
Pause,
|
|
54
|
+
Play,
|
|
55
|
+
Plus,
|
|
56
|
+
Presentation,
|
|
57
|
+
Save,
|
|
58
|
+
Scan,
|
|
59
|
+
Search,
|
|
60
|
+
Settings,
|
|
61
|
+
Settings2,
|
|
62
|
+
Slack,
|
|
63
|
+
Square,
|
|
64
|
+
Sun,
|
|
65
|
+
Terminal,
|
|
66
|
+
TvMinimalPlay,
|
|
67
|
+
Upload,
|
|
68
|
+
UserRound,
|
|
69
|
+
UsersRound,
|
|
70
|
+
Workflow,
|
|
71
|
+
Wrench,
|
|
72
|
+
X,
|
|
73
|
+
type LucideIcon,
|
|
74
|
+
} from 'lucide-react';
|
|
75
|
+
import type { ReactNode } from 'react';
|
|
76
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
77
|
+
|
|
78
|
+
export const NM_LUCIDE_FILLED_IDS = new Set<string>(['stop']);
|
|
79
|
+
|
|
80
|
+
const LUCIDE: Partial<
|
|
81
|
+
Record<NmIconId | 'square-dashed-bottom-code' | 'layout-grid' | 'stop' | 'scan' | 'pause', LucideIcon>
|
|
82
|
+
> = {
|
|
83
|
+
plus: Plus,
|
|
84
|
+
expand: Maximize2,
|
|
85
|
+
scan: Scan,
|
|
86
|
+
reload: RotateCcw,
|
|
87
|
+
user: UserRound,
|
|
88
|
+
paperclip: Plus,
|
|
89
|
+
settings: Settings,
|
|
90
|
+
mic: Mic,
|
|
91
|
+
'mic-off': MicOff,
|
|
92
|
+
'audio-lines': AudioLines,
|
|
93
|
+
send: ArrowUp,
|
|
94
|
+
stop: Square,
|
|
95
|
+
chevron: ChevronDown,
|
|
96
|
+
check: Check,
|
|
97
|
+
'circle-check': CircleCheck,
|
|
98
|
+
code: Code,
|
|
99
|
+
'file-code': FileCode2,
|
|
100
|
+
console: FileCode2,
|
|
101
|
+
'mouse-pointer': SquareDashedMousePointer,
|
|
102
|
+
copy: Copy,
|
|
103
|
+
globe: Globe,
|
|
104
|
+
chat: MessageCircle,
|
|
105
|
+
'chat-dashed': MessageCircleDashed,
|
|
106
|
+
folder: Folder,
|
|
107
|
+
bot: Bot,
|
|
108
|
+
app: AppWindowMac,
|
|
109
|
+
layers: Box,
|
|
110
|
+
users: UsersRound,
|
|
111
|
+
building: Building,
|
|
112
|
+
'file-text': FileText,
|
|
113
|
+
wrench: Wrench,
|
|
114
|
+
file: File,
|
|
115
|
+
brain: Brain,
|
|
116
|
+
library: LibraryBig,
|
|
117
|
+
'layout-grid': LayoutGrid,
|
|
118
|
+
panel: PanelRight,
|
|
119
|
+
pause: Pause,
|
|
120
|
+
play: Play,
|
|
121
|
+
workflow: Workflow,
|
|
122
|
+
ellipsis: Ellipsis,
|
|
123
|
+
spreadsheet: MonitorStop,
|
|
124
|
+
'square-dashed-bottom-code': SquareDashedBottomCode,
|
|
125
|
+
cable: Cable,
|
|
126
|
+
menu: Menu,
|
|
127
|
+
loader: LoaderCircle,
|
|
128
|
+
monitor: MonitorStop,
|
|
129
|
+
server: Server,
|
|
130
|
+
filter: ListFilter,
|
|
131
|
+
sliders: Settings2,
|
|
132
|
+
upload: Upload,
|
|
133
|
+
image: Image,
|
|
134
|
+
'image-plus': ImagePlus,
|
|
135
|
+
music: Music,
|
|
136
|
+
headphones: Headphones,
|
|
137
|
+
video: TvMinimalPlay,
|
|
138
|
+
search: Search,
|
|
139
|
+
presentation: Presentation,
|
|
140
|
+
terminal: Terminal,
|
|
141
|
+
x: X,
|
|
142
|
+
save: Save,
|
|
143
|
+
mail: Mail,
|
|
144
|
+
calendar: Calendar,
|
|
145
|
+
clock: Clock,
|
|
146
|
+
gauge: Gauge,
|
|
147
|
+
minus: Minus,
|
|
148
|
+
'hard-drive': HardDrive,
|
|
149
|
+
slack: Slack,
|
|
150
|
+
github: Github,
|
|
151
|
+
sun: Sun,
|
|
152
|
+
moon: Moon,
|
|
153
|
+
'arrow-left': ArrowLeft,
|
|
154
|
+
'arrow-right': ArrowRight,
|
|
155
|
+
'panel-left': PanelLeft,
|
|
156
|
+
rows: Rows2,
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
export function hasNmLucide(id: string): boolean {
|
|
160
|
+
return id in LUCIDE;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export function NmLucide({ id, className }: { id: string; className?: string }): ReactNode {
|
|
164
|
+
const Icon = LUCIDE[id as NmIconId | 'square-dashed-bottom-code' | 'layout-grid' | 'stop'];
|
|
165
|
+
if (Icon == null) {
|
|
166
|
+
return null;
|
|
167
|
+
}
|
|
168
|
+
const filled = NM_LUCIDE_FILLED_IDS.has(id);
|
|
169
|
+
const baseClass = filled ? 'nm-icon nm-icon--filled' : 'nm-icon';
|
|
170
|
+
const iconClass = className == null ? baseClass : `${baseClass} ${className}`;
|
|
171
|
+
return (
|
|
172
|
+
<Icon
|
|
173
|
+
className={iconClass}
|
|
174
|
+
data-icon={id}
|
|
175
|
+
strokeWidth={filled ? undefined : 2}
|
|
176
|
+
aria-hidden
|
|
177
|
+
focusable="false"
|
|
178
|
+
/>
|
|
179
|
+
);
|
|
180
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { MouseEvent as ReactMouseEvent, ReactNode, Ref } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
import { NordmanIconButton } from '../nordman-icon-button/nordman-icon-button.tsx';
|
|
4
|
+
import { NM_ICON_BUTTON_TONES } from '../../config/nm-icon-button.ts';
|
|
5
|
+
import { createLogger } from '../../kit-logger.ts';
|
|
6
|
+
|
|
7
|
+
const logger = createLogger('interface-nm-icon-border');
|
|
8
|
+
|
|
9
|
+
export type NmIconBorderProps = {
|
|
10
|
+
label: string;
|
|
11
|
+
icon?: NmIconId;
|
|
12
|
+
imageSrc?: string;
|
|
13
|
+
pressed?: boolean;
|
|
14
|
+
checked?: boolean;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
ariaDisabled?: boolean;
|
|
17
|
+
busy?: boolean;
|
|
18
|
+
expanded?: boolean;
|
|
19
|
+
popup?: 'listbox';
|
|
20
|
+
controls?: string;
|
|
21
|
+
buttonRef?: Ref<HTMLButtonElement>;
|
|
22
|
+
className?: string;
|
|
23
|
+
children?: ReactNode;
|
|
24
|
+
testId?: string;
|
|
25
|
+
onClick?: (event: ReactMouseEvent<HTMLButtonElement>) => void;
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export function NmIconBorder(props: NmIconBorderProps): ReactNode {
|
|
29
|
+
logger.debug('render', props.label, {
|
|
30
|
+
icon: props.icon,
|
|
31
|
+
pressed: props.pressed === true,
|
|
32
|
+
disabled: props.disabled === true,
|
|
33
|
+
});
|
|
34
|
+
return (
|
|
35
|
+
<NordmanIconButton
|
|
36
|
+
ref={props.buttonRef}
|
|
37
|
+
label={props.label}
|
|
38
|
+
glyph={props.icon}
|
|
39
|
+
imageSrc={props.imageSrc}
|
|
40
|
+
tone={NM_ICON_BUTTON_TONES.subtle}
|
|
41
|
+
pressed={props.pressed}
|
|
42
|
+
checked={props.checked}
|
|
43
|
+
disabled={props.disabled}
|
|
44
|
+
ariaDisabled={props.ariaDisabled}
|
|
45
|
+
busy={props.busy}
|
|
46
|
+
expanded={props.expanded}
|
|
47
|
+
popup={props.popup}
|
|
48
|
+
controls={props.controls}
|
|
49
|
+
className={props.className}
|
|
50
|
+
testId={props.testId}
|
|
51
|
+
onClick={props.onClick}
|
|
52
|
+
>
|
|
53
|
+
{props.children}
|
|
54
|
+
</NordmanIconButton>
|
|
55
|
+
);
|
|
56
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
.nm-input {
|
|
2
|
+
box-sizing: border-box;
|
|
3
|
+
width: 100%;
|
|
4
|
+
min-width: 0;
|
|
5
|
+
height: var(--nm-field-h);
|
|
6
|
+
padding: 0 var(--control-px);
|
|
7
|
+
border: var(--nm-rule) solid var(--nm-line-strong);
|
|
8
|
+
border-radius: var(--nm-control-r);
|
|
9
|
+
background: var(--nm-raised);
|
|
10
|
+
color: var(--nm-fg);
|
|
11
|
+
color-scheme: inherit;
|
|
12
|
+
font-family: var(--nm-font);
|
|
13
|
+
font-size: var(--control-fs);
|
|
14
|
+
font-weight: var(--nm-weight-regular);
|
|
15
|
+
line-height: var(--nm-leading-ui);
|
|
16
|
+
outline: none;
|
|
17
|
+
transition: border-color 0.15s;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.nm-input::placeholder {
|
|
21
|
+
color: var(--nm-fg-subtle);
|
|
22
|
+
opacity: 1;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.nm-input:hover:not(:disabled) {
|
|
26
|
+
border-color: var(--nm-stroke);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.nm-input:focus-visible {
|
|
30
|
+
border-color: var(--nm-fg);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.nm-input:disabled {
|
|
34
|
+
cursor: not-allowed;
|
|
35
|
+
opacity: 0.5;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.nm-input[aria-invalid='true'],
|
|
39
|
+
.nm-input[data-invalid] {
|
|
40
|
+
border-color: var(--nm-destructive);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.nm-input[type='file'] {
|
|
44
|
+
padding: 0 var(--control-px) 0 0;
|
|
45
|
+
line-height: var(--nm-field-h);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.nm-input[type='file']::file-selector-button {
|
|
49
|
+
height: 100%;
|
|
50
|
+
margin-right: var(--control-px);
|
|
51
|
+
padding: 0 var(--control-px);
|
|
52
|
+
border: 0;
|
|
53
|
+
border-right: var(--nm-rule) solid var(--nm-line-strong);
|
|
54
|
+
background: var(--nm-panel);
|
|
55
|
+
color: var(--nm-fg);
|
|
56
|
+
font: inherit;
|
|
57
|
+
cursor: pointer;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.nm-input[type='date'],
|
|
61
|
+
.nm-input[type='time'],
|
|
62
|
+
.nm-input[type='datetime-local'],
|
|
63
|
+
.nm-input[type='month'],
|
|
64
|
+
.nm-input[type='week'] {
|
|
65
|
+
min-width: var(--nm-width-date);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.nm-input::-webkit-calendar-picker-indicator {
|
|
69
|
+
cursor: pointer;
|
|
70
|
+
opacity: 0.6;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.nm-input::-webkit-calendar-picker-indicator:hover {
|
|
74
|
+
opacity: 1;
|
|
75
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Input as InputPrimitive } from '@base-ui/react/input';
|
|
2
|
+
import { nmClass } from '../../lib/nm-class.ts';
|
|
3
|
+
|
|
4
|
+
/** Base UI Input, in the shadcn composition. Text, email, password, number, search, tel, url, date, time and more. */
|
|
5
|
+
export function NmInput({ className, type, ...props }: InputPrimitive.Props & { type?: string }) {
|
|
6
|
+
return <InputPrimitive data-slot="input" type={type} className={nmClass('nm-input', className as string)} {...props} />;
|
|
7
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
.nm-input-group {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
box-sizing: border-box;
|
|
5
|
+
width: 100%;
|
|
6
|
+
height: var(--nm-field-h);
|
|
7
|
+
border: var(--nm-rule) solid var(--nm-line-strong);
|
|
8
|
+
border-radius: var(--nm-control-r);
|
|
9
|
+
background: var(--nm-raised);
|
|
10
|
+
transition: border-color 0.15s;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.nm-input-group:hover {
|
|
14
|
+
border-color: var(--nm-stroke);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.nm-input-group:focus-within {
|
|
18
|
+
border-color: var(--nm-fg);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.nm-input-group:has([aria-invalid='true']) {
|
|
22
|
+
border-color: var(--nm-destructive);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.nm-input-group__addon {
|
|
26
|
+
display: flex;
|
|
27
|
+
flex-shrink: 0;
|
|
28
|
+
align-items: center;
|
|
29
|
+
gap: var(--nm-space-8);
|
|
30
|
+
padding: 0 var(--control-px);
|
|
31
|
+
color: var(--nm-fg-subtle);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.nm-input-group__addon[data-align='inline-start'] {
|
|
35
|
+
order: -1;
|
|
36
|
+
padding-right: 0;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.nm-input-group__addon[data-align='inline-end'] {
|
|
40
|
+
order: 1;
|
|
41
|
+
padding-left: 0;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.nm-input-group__text {
|
|
45
|
+
font-family: var(--nm-font);
|
|
46
|
+
font-size: var(--control-fs);
|
|
47
|
+
white-space: nowrap;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.nm-input-group__control {
|
|
51
|
+
flex: 1;
|
|
52
|
+
min-width: 0;
|
|
53
|
+
height: 100%;
|
|
54
|
+
padding: 0 var(--control-px);
|
|
55
|
+
border: 0;
|
|
56
|
+
background: transparent;
|
|
57
|
+
color: var(--nm-fg);
|
|
58
|
+
font-family: var(--nm-font);
|
|
59
|
+
font-size: var(--control-fs);
|
|
60
|
+
outline: none;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.nm-input-group__control::placeholder {
|
|
64
|
+
color: var(--nm-fg-subtle);
|
|
65
|
+
opacity: 1;
|
|
66
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
import { Input as InputPrimitive } from '@base-ui/react/input';
|
|
3
|
+
import { nmClass } from '../../lib/nm-class.ts';
|
|
4
|
+
|
|
5
|
+
/** An input with something attached: an icon, a unit, a button. The group draws the frame. */
|
|
6
|
+
export function NmInputGroup({ className, ...props }: ComponentProps<'div'>) {
|
|
7
|
+
return <div data-slot="input-group" role="group" className={nmClass('nm-input-group', className)} {...props} />;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export function NmInputGroupAddon({ className, align = 'inline-start', ...props }: ComponentProps<'div'> & { align?: 'inline-start' | 'inline-end' }) {
|
|
11
|
+
return <div data-slot="input-group-addon" data-align={align} className={nmClass('nm-input-group__addon', className)} {...props} />;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export function NmInputGroupText({ className, ...props }: ComponentProps<'span'>) {
|
|
15
|
+
return <span className={nmClass('nm-input-group__text', className)} {...props} />;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export function NmInputGroupInput({ className, ...props }: InputPrimitive.Props) {
|
|
19
|
+
return <InputPrimitive data-slot="input-group-control" className={nmClass('nm-input-group__control', className as string)} {...props} />;
|
|
20
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
.nm-label {
|
|
2
|
+
display: inline-flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
gap: var(--nm-space-8);
|
|
5
|
+
color: var(--nm-fg);
|
|
6
|
+
font-family: var(--nm-font);
|
|
7
|
+
font-size: var(--nm-type-ui);
|
|
8
|
+
font-weight: var(--nm-weight-medium);
|
|
9
|
+
line-height: var(--nm-leading-snug);
|
|
10
|
+
user-select: none;
|
|
11
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
import { nmClass } from '../../lib/nm-class.ts';
|
|
3
|
+
|
|
4
|
+
export function NmLabel({ className, ...props }: ComponentProps<'label'>) {
|
|
5
|
+
return <label data-slot="label" className={nmClass('nm-label', className)} {...props} />;
|
|
6
|
+
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
.nm-list-item {
|
|
2
|
+
box-sizing: border-box;
|
|
3
|
+
display: flex;
|
|
4
|
+
align-items: center;
|
|
5
|
+
justify-content: space-between;
|
|
6
|
+
gap: var(--nm-space-8);
|
|
7
|
+
height: var(--nm-list-row);
|
|
8
|
+
min-height: var(--nm-list-row);
|
|
9
|
+
max-height: var(--nm-list-row);
|
|
10
|
+
padding: var(--nm-space-12) var(--nm-row-inline);
|
|
11
|
+
border-radius: var(--nm-field-radius);
|
|
12
|
+
background: var(--nm-raised);
|
|
13
|
+
color: var(--nm-stroke);
|
|
14
|
+
font-family: var(--nm-font);
|
|
15
|
+
font-size: var(--nm-type-ui);
|
|
16
|
+
font-weight: var(--nm-weight-medium);
|
|
17
|
+
line-height: var(--nm-leading-ui);
|
|
18
|
+
letter-spacing: var(--nm-track);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.nm-list-item--marked {
|
|
22
|
+
padding-block: var(--nm-space-6);
|
|
23
|
+
color: var(--nm-fg);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.nm-list-item--icon {
|
|
27
|
+
color: var(--nm-fg-subtle);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.nm-list-item--face {
|
|
31
|
+
height: auto;
|
|
32
|
+
min-height: calc(var(--nm-list-face) + var(--nm-space-12) * 2);
|
|
33
|
+
max-height: none;
|
|
34
|
+
padding: var(--nm-space-12) var(--nm-row-inline);
|
|
35
|
+
background: transparent;
|
|
36
|
+
color: var(--nm-fg);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.nm-list-item--face .nm-list-item__lead {
|
|
40
|
+
width: var(--nm-list-face);
|
|
41
|
+
height: var(--nm-list-face);
|
|
42
|
+
overflow: hidden;
|
|
43
|
+
border-radius: calc(var(--nm-list-face) / 2);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.nm-list-item--face .nm-list-item__lead svg {
|
|
47
|
+
display: block;
|
|
48
|
+
width: 100%;
|
|
49
|
+
height: 100%;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.nm-list-item--face > span > .nm-icon,
|
|
53
|
+
.nm-list-item__rest .nm-icon {
|
|
54
|
+
color: var(--nm-fg-subtle);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.nm-list-item__rest .nm-icon {
|
|
58
|
+
display: block;
|
|
59
|
+
box-sizing: content-box;
|
|
60
|
+
width: var(--nm-icon-button);
|
|
61
|
+
height: var(--nm-icon-button);
|
|
62
|
+
padding: var(--nm-icon-pad);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.nm-list-item__identity {
|
|
66
|
+
display: flex;
|
|
67
|
+
align-items: center;
|
|
68
|
+
gap: var(--nm-space-8);
|
|
69
|
+
min-width: 0;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.nm-list-item__lead {
|
|
73
|
+
display: flex;
|
|
74
|
+
align-items: center;
|
|
75
|
+
justify-content: center;
|
|
76
|
+
flex: 0 0 auto;
|
|
77
|
+
width: var(--nm-icon-button);
|
|
78
|
+
height: var(--nm-icon-button);
|
|
79
|
+
background: transparent;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.nm-list-item__lead > *,
|
|
83
|
+
.nm-list-item:not(.nm-list-item--face) .nm-list-item__lead svg {
|
|
84
|
+
display: block;
|
|
85
|
+
width: var(--nm-icon-button);
|
|
86
|
+
height: var(--nm-icon-button);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.nm-list-item__title {
|
|
90
|
+
min-width: 0;
|
|
91
|
+
overflow: hidden;
|
|
92
|
+
text-overflow: ellipsis;
|
|
93
|
+
white-space: nowrap;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.nm-list-item__open {
|
|
97
|
+
min-width: 0;
|
|
98
|
+
padding: 0;
|
|
99
|
+
border: 0;
|
|
100
|
+
background: transparent;
|
|
101
|
+
color: inherit;
|
|
102
|
+
font: inherit;
|
|
103
|
+
letter-spacing: inherit;
|
|
104
|
+
line-height: inherit;
|
|
105
|
+
text-align: start;
|
|
106
|
+
cursor: pointer;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.nm-list-item__detail {
|
|
110
|
+
color: var(--nm-line);
|
|
111
|
+
white-space: nowrap;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.nm-list-item__action {
|
|
115
|
+
display: inline-flex;
|
|
116
|
+
flex: 0 0 auto;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.nm-list-item > span > .nm-icon {
|
|
120
|
+
display: block;
|
|
121
|
+
box-sizing: content-box;
|
|
122
|
+
width: var(--nm-icon-button);
|
|
123
|
+
height: var(--nm-icon-button);
|
|
124
|
+
padding: var(--nm-icon-pad);
|
|
125
|
+
color: var(--nm-stroke);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.nm-list-item__menu {
|
|
129
|
+
display: inline-flex;
|
|
130
|
+
padding: 0;
|
|
131
|
+
border: 0;
|
|
132
|
+
background: transparent;
|
|
133
|
+
color: var(--nm-fg);
|
|
134
|
+
cursor: pointer;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.nm-list-item__menu .nm-icon {
|
|
138
|
+
display: block;
|
|
139
|
+
box-sizing: content-box;
|
|
140
|
+
width: var(--nm-icon-button);
|
|
141
|
+
height: var(--nm-icon-button);
|
|
142
|
+
padding: var(--nm-icon-pad);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.nm-list-item__menu .nm-dropdown .nm-icon {
|
|
146
|
+
padding: 0;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.nm-list-item:hover,
|
|
150
|
+
.nm-list-item:focus-within {
|
|
151
|
+
padding-block: var(--nm-space-6);
|
|
152
|
+
background: var(--nm-inset);
|
|
153
|
+
color: var(--nm-fg);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.nm-list-item:has(.nm-list-item__action):hover,
|
|
157
|
+
.nm-list-item:has(.nm-list-item__action):focus-within {
|
|
158
|
+
padding-block: var(--nm-space-12);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.nm-list-item--face:hover,
|
|
162
|
+
.nm-list-item--face:focus-within {
|
|
163
|
+
padding: var(--nm-space-12) var(--nm-row-inline);
|
|
164
|
+
background: var(--nm-inset);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.nm-list-item:hover .nm-list-item__detail,
|
|
168
|
+
.nm-list-item:focus-within .nm-list-item__detail,
|
|
169
|
+
.nm-list-item:hover .nm-list-item__rest,
|
|
170
|
+
.nm-list-item:focus-within .nm-list-item__rest {
|
|
171
|
+
display: none;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
.nm-list-item:has(.nm-list-item__action, .nm-list-item__menu, .nm-list-item__rest) {
|
|
176
|
+
padding-right: var(--nm-row-inline-end);
|
|
177
|
+
}
|