@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
package/dist/tokens.css
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/* Nordman design tokens: the one source for every colour on every Nordman page.
|
|
2
|
+
The website sets the theme with data-theme, the apps with html.light and html.dark.
|
|
3
|
+
--nm-* are the app names for the same values. Apps set them inline for custom appearance. */
|
|
4
|
+
:root{
|
|
5
|
+
--bg:#ffffff; --bg-2:#fafafa; --bg-3:#f2f2f2;
|
|
6
|
+
--fg:#171717; --fg-2:#666666; --fg-3:#8f8f8f;
|
|
7
|
+
--line:#ebebeb; --line-2:#e0e0e0;
|
|
8
|
+
--btn:#171717; --btn-fg:#ffffff; --btn-2:#ffffff;
|
|
9
|
+
--glow:0,0,0; --glow-a:.16;
|
|
10
|
+
--ok:#16a34a; --focus:#0070f3;
|
|
11
|
+
--header:rgba(255,255,255,.85);
|
|
12
|
+
--nm-stroke:var(--fg-2);
|
|
13
|
+
--nm-canvas-rgb:255 255 255; --nm-fg-rgb:23 23 23;
|
|
14
|
+
--nm-fg-muted-rgb:102 102 102; --nm-fg-subtle-rgb:102 102 102; --nm-stroke-rgb:102 102 102;
|
|
15
|
+
--nm-line-rgb:235 235 235; --nm-panel-rgb:242 242 242; --nm-raised-rgb:250 250 250; --nm-inset-rgb:242 242 242;
|
|
16
|
+
color-scheme:light;
|
|
17
|
+
--nm-canvas:var(--bg); --nm-fg:var(--fg);
|
|
18
|
+
--nm-fg-muted:var(--fg-2); --nm-fg-subtle:var(--fg-2);
|
|
19
|
+
--nm-line:var(--line); --nm-line-strong:var(--line-2);
|
|
20
|
+
--nm-panel:var(--bg-3); --nm-raised:var(--bg-2); --nm-inset:var(--bg-3);
|
|
21
|
+
|
|
22
|
+
/* One geometry for controls on every page. */
|
|
23
|
+
--control-h:32px; --control-h-sm:28px; --control-h-lg:40px;
|
|
24
|
+
--control-r:6px; --control-px:calc(12px * var(--nm-space-scale, 1)); --control-gap:calc(8px * var(--nm-space-scale, 1));
|
|
25
|
+
--control-fs:14px; --control-fw:var(--nm-weight-medium); --btn-hover:.88;
|
|
26
|
+
--field-label-fs:13px; --field-label-gap:calc(6px * var(--nm-space-scale, 1)); --field-area-py:calc(10px * var(--nm-space-scale, 1));
|
|
27
|
+
--tab-py:calc(10px * var(--nm-space-scale, 1)); --tab-px:calc(14px * var(--nm-space-scale, 1)); --tab-rule:2px;
|
|
28
|
+
--toggle-pad:calc(3px * var(--nm-space-scale, 1)); --toggle-h:30px; --toggle-px:calc(14px * var(--nm-space-scale, 1)); --toggle-r:999px;
|
|
29
|
+
--badge-h:20px; --badge-px:calc(8px * var(--nm-space-scale, 1)); --badge-fs:11px; --badge-r:999px;
|
|
30
|
+
--table-fs:15px; --table-head-fs:13px; --table-head-py:calc(12px * var(--nm-space-scale, 1)); --table-cell-py:calc(16px * var(--nm-space-scale, 1)); --table-gap:calc(16px * var(--nm-space-scale, 1));
|
|
31
|
+
}
|
|
32
|
+
@media (prefers-color-scheme:dark){
|
|
33
|
+
:root:not([data-theme="light"]):not(.light){
|
|
34
|
+
--bg:#000000; --bg-2:#0a0a0a; --bg-3:#1a1a1a;
|
|
35
|
+
--fg:#ededed; --fg-2:#a1a1a1; --fg-3:#707070;
|
|
36
|
+
--line:#1f1f1f; --line-2:#2e2e2e;
|
|
37
|
+
--btn:#ededed; --btn-fg:#0a0a0a; --btn-2:#0a0a0a;
|
|
38
|
+
--glow:255,255,255; --glow-a:.5;
|
|
39
|
+
--ok:#3fcf75; --focus:#52a8ff;
|
|
40
|
+
--header:rgba(0,0,0,.8);
|
|
41
|
+
--nm-stroke:var(--fg-3);
|
|
42
|
+
--nm-canvas-rgb:0 0 0; --nm-fg-rgb:237 237 237;
|
|
43
|
+
--nm-fg-muted-rgb:161 161 161; --nm-fg-subtle-rgb:161 161 161; --nm-stroke-rgb:112 112 112;
|
|
44
|
+
--nm-line-rgb:31 31 31; --nm-panel-rgb:26 26 26; --nm-raised-rgb:10 10 10; --nm-inset-rgb:26 26 26;
|
|
45
|
+
color-scheme:dark;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
:root[data-theme="dark"],:root.dark:not([data-theme="light"]){
|
|
49
|
+
--bg:#000000; --bg-2:#0a0a0a; --bg-3:#1a1a1a;
|
|
50
|
+
--fg:#ededed; --fg-2:#a1a1a1; --fg-3:#707070;
|
|
51
|
+
--line:#1f1f1f; --line-2:#2e2e2e;
|
|
52
|
+
--btn:#ededed; --btn-fg:#0a0a0a; --btn-2:#0a0a0a;
|
|
53
|
+
--glow:255,255,255; --glow-a:.5;
|
|
54
|
+
--ok:#3fcf75; --focus:#52a8ff;
|
|
55
|
+
--header:rgba(0,0,0,.8);
|
|
56
|
+
--nm-stroke:var(--fg-3);
|
|
57
|
+
--nm-canvas-rgb:0 0 0; --nm-fg-rgb:237 237 237;
|
|
58
|
+
--nm-fg-muted-rgb:161 161 161; --nm-fg-subtle-rgb:161 161 161; --nm-stroke-rgb:112 112 112;
|
|
59
|
+
--nm-line-rgb:31 31 31; --nm-panel-rgb:26 26 26; --nm-raised-rgb:10 10 10; --nm-inset-rgb:26 26 26;
|
|
60
|
+
color-scheme:dark;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/* Typeface. The one family every Nordman component and page sets its text in.
|
|
64
|
+
Poppins and Geist Mono are loaded by the app, or by @nordmanai/nif. Nothing may name another family. */
|
|
65
|
+
:root{
|
|
66
|
+
--nm-font:'Poppins',system-ui,-apple-system,'Segoe UI',sans-serif;
|
|
67
|
+
--nm-font-mono:'Geist Mono',ui-monospace,'SF Mono',Menlo,Consolas,monospace;
|
|
68
|
+
--nm-weight-light:300; --nm-weight-regular:400; --nm-weight-medium:500; --nm-weight-semibold:600; --nm-weight-bold:700;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/* One height for every field: input, select, date, colour, input group. Content never changes it. */
|
|
72
|
+
:root{ --nm-field-h:var(--control-h-lg); }
|
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { type NmAiBadgeTone, type NmAiStatus, type NmToolState } from '../../config/nm-ai.ts';
|
|
3
|
+
export declare function NmBubble(props: {
|
|
4
|
+
role: 'user' | 'assistant';
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
}): ReactNode;
|
|
7
|
+
export declare function NmBadge(props: {
|
|
8
|
+
tone?: NmAiBadgeTone;
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
}): ReactNode;
|
|
11
|
+
export declare function NmItem(props: {
|
|
12
|
+
media?: ReactNode;
|
|
13
|
+
title: ReactNode;
|
|
14
|
+
description?: ReactNode;
|
|
15
|
+
actions?: ReactNode;
|
|
16
|
+
}): ReactNode;
|
|
17
|
+
export declare function NmSheet(props: {
|
|
18
|
+
title: string;
|
|
19
|
+
description?: string;
|
|
20
|
+
onClose: () => void;
|
|
21
|
+
children: ReactNode;
|
|
22
|
+
}): ReactNode;
|
|
23
|
+
export type NmAiMessageAction = {
|
|
24
|
+
id: string;
|
|
25
|
+
label: string;
|
|
26
|
+
icon: 'copy' | 'reload' | 'pen' | 'check' | 'volume' | 'fork';
|
|
27
|
+
};
|
|
28
|
+
export declare function NmMessage(props: {
|
|
29
|
+
role: 'user' | 'assistant';
|
|
30
|
+
children: ReactNode;
|
|
31
|
+
actions?: readonly NmAiMessageAction[];
|
|
32
|
+
onAction?: (id: string) => void;
|
|
33
|
+
footer?: ReactNode;
|
|
34
|
+
}): ReactNode;
|
|
35
|
+
export declare function NmReasoning(props: {
|
|
36
|
+
text: string;
|
|
37
|
+
streaming?: boolean;
|
|
38
|
+
seconds?: number;
|
|
39
|
+
defaultOpen?: boolean;
|
|
40
|
+
}): ReactNode;
|
|
41
|
+
export type NmChainStep = {
|
|
42
|
+
id: string;
|
|
43
|
+
title: string;
|
|
44
|
+
status: NmAiStatus;
|
|
45
|
+
detail?: string;
|
|
46
|
+
results?: readonly string[];
|
|
47
|
+
};
|
|
48
|
+
export declare function NmChainOfThought(props: {
|
|
49
|
+
summary: string;
|
|
50
|
+
steps: readonly NmChainStep[];
|
|
51
|
+
defaultOpen?: boolean;
|
|
52
|
+
}): ReactNode;
|
|
53
|
+
export declare function NmCheckpoint(props: {
|
|
54
|
+
label: string;
|
|
55
|
+
restoreLabel?: string;
|
|
56
|
+
onRestore?: () => void;
|
|
57
|
+
}): ReactNode;
|
|
58
|
+
export type NmConfirmationState = 'requested' | 'approved' | 'denied';
|
|
59
|
+
export declare function NmConfirmation(props: {
|
|
60
|
+
title: string;
|
|
61
|
+
description?: string;
|
|
62
|
+
state: NmConfirmationState;
|
|
63
|
+
onApprove?: () => void;
|
|
64
|
+
onDeny?: () => void;
|
|
65
|
+
}): ReactNode;
|
|
66
|
+
export declare function NmContext(props: {
|
|
67
|
+
used: number;
|
|
68
|
+
max: number;
|
|
69
|
+
breakdown?: readonly {
|
|
70
|
+
label: string;
|
|
71
|
+
value: number;
|
|
72
|
+
}[];
|
|
73
|
+
}): ReactNode;
|
|
74
|
+
export type NmFileNode = {
|
|
75
|
+
name: string;
|
|
76
|
+
children?: readonly NmFileNode[];
|
|
77
|
+
};
|
|
78
|
+
type TreeSelection = {
|
|
79
|
+
selected?: string;
|
|
80
|
+
onSelect?: (path: string) => void;
|
|
81
|
+
};
|
|
82
|
+
/** Folders open and close. Give it `onSelect` and a file can be chosen. `selected` is its path, like `src/App.tsx`. */
|
|
83
|
+
export declare function NmFileTree(props: {
|
|
84
|
+
nodes: readonly NmFileNode[];
|
|
85
|
+
defaultOpen?: boolean;
|
|
86
|
+
} & TreeSelection): ReactNode;
|
|
87
|
+
export declare function NmInlineCitation(props: {
|
|
88
|
+
label: string;
|
|
89
|
+
title: string;
|
|
90
|
+
url: string;
|
|
91
|
+
excerpt?: string;
|
|
92
|
+
}): ReactNode;
|
|
93
|
+
export declare function NmModelSelector(props: {
|
|
94
|
+
models: readonly {
|
|
95
|
+
id: string;
|
|
96
|
+
label: string;
|
|
97
|
+
}[];
|
|
98
|
+
model: string;
|
|
99
|
+
onModel: (id: string) => void;
|
|
100
|
+
efforts: readonly {
|
|
101
|
+
id: string;
|
|
102
|
+
label: string;
|
|
103
|
+
}[];
|
|
104
|
+
effort: string;
|
|
105
|
+
onEffort: (id: string) => void;
|
|
106
|
+
}): ReactNode;
|
|
107
|
+
export type NmPlanStep = {
|
|
108
|
+
id: string;
|
|
109
|
+
title: string;
|
|
110
|
+
status: NmAiStatus;
|
|
111
|
+
detail?: string;
|
|
112
|
+
};
|
|
113
|
+
export declare function NmPlan(props: {
|
|
114
|
+
title: string;
|
|
115
|
+
steps: readonly NmPlanStep[];
|
|
116
|
+
defaultOpen?: boolean;
|
|
117
|
+
}): ReactNode;
|
|
118
|
+
export type NmQueueItem = {
|
|
119
|
+
id: string;
|
|
120
|
+
title: string;
|
|
121
|
+
description?: string;
|
|
122
|
+
};
|
|
123
|
+
export declare function NmQueue(props: {
|
|
124
|
+
remaining: readonly NmQueueItem[];
|
|
125
|
+
completed: readonly NmQueueItem[];
|
|
126
|
+
defaultOpen?: boolean;
|
|
127
|
+
}): ReactNode;
|
|
128
|
+
export type NmTaskStep = {
|
|
129
|
+
id: string;
|
|
130
|
+
title: string;
|
|
131
|
+
status: NmAiStatus;
|
|
132
|
+
icon?: 'search' | 'file';
|
|
133
|
+
};
|
|
134
|
+
export declare function NmTask(props: {
|
|
135
|
+
title: string;
|
|
136
|
+
steps: readonly NmTaskStep[];
|
|
137
|
+
}): ReactNode;
|
|
138
|
+
export declare function NmSources(props: {
|
|
139
|
+
sources: readonly {
|
|
140
|
+
title: string;
|
|
141
|
+
url: string;
|
|
142
|
+
}[];
|
|
143
|
+
defaultOpen?: boolean;
|
|
144
|
+
}): ReactNode;
|
|
145
|
+
export declare function NmTerminal(props: {
|
|
146
|
+
command: string;
|
|
147
|
+
output?: string;
|
|
148
|
+
exitCode?: number;
|
|
149
|
+
running?: boolean;
|
|
150
|
+
defaultOpen?: boolean;
|
|
151
|
+
}): ReactNode;
|
|
152
|
+
export type NmStackFrame = {
|
|
153
|
+
fn: string;
|
|
154
|
+
file: string;
|
|
155
|
+
line: number;
|
|
156
|
+
internal?: boolean;
|
|
157
|
+
};
|
|
158
|
+
export declare function NmStackTrace(props: {
|
|
159
|
+
error: string;
|
|
160
|
+
frames: readonly NmStackFrame[];
|
|
161
|
+
defaultOpen?: boolean;
|
|
162
|
+
}): ReactNode;
|
|
163
|
+
export type NmTestStatus = 'passed' | 'failed' | 'skipped';
|
|
164
|
+
export type NmTestSuite = {
|
|
165
|
+
name: string;
|
|
166
|
+
tests: readonly {
|
|
167
|
+
name: string;
|
|
168
|
+
status: NmTestStatus;
|
|
169
|
+
error?: string;
|
|
170
|
+
}[];
|
|
171
|
+
};
|
|
172
|
+
export declare function NmTestResults(props: {
|
|
173
|
+
suites: readonly NmTestSuite[];
|
|
174
|
+
defaultOpen?: boolean;
|
|
175
|
+
}): ReactNode;
|
|
176
|
+
export declare function NmTool(props: {
|
|
177
|
+
name: string;
|
|
178
|
+
state: NmToolState;
|
|
179
|
+
input?: string;
|
|
180
|
+
output?: string;
|
|
181
|
+
error?: string;
|
|
182
|
+
onApprove?: () => void;
|
|
183
|
+
onDeny?: () => void;
|
|
184
|
+
defaultOpen?: boolean;
|
|
185
|
+
}): ReactNode;
|
|
186
|
+
export declare function NmSubagent(props: {
|
|
187
|
+
name: string;
|
|
188
|
+
task: string;
|
|
189
|
+
status: NmAiStatus;
|
|
190
|
+
tools?: readonly {
|
|
191
|
+
id: string;
|
|
192
|
+
title: string;
|
|
193
|
+
status: NmAiStatus;
|
|
194
|
+
}[];
|
|
195
|
+
result?: string;
|
|
196
|
+
defaultOpen?: boolean;
|
|
197
|
+
}): ReactNode;
|
|
198
|
+
export declare function NmSuggestions(props: {
|
|
199
|
+
items: readonly string[];
|
|
200
|
+
onPick: (text: string) => void;
|
|
201
|
+
disabled?: boolean;
|
|
202
|
+
}): ReactNode;
|
|
203
|
+
export type NmChatTurn = {
|
|
204
|
+
id: string;
|
|
205
|
+
role: 'user' | 'assistant';
|
|
206
|
+
text: string;
|
|
207
|
+
reasoning?: string;
|
|
208
|
+
tool?: {
|
|
209
|
+
name: string;
|
|
210
|
+
state: NmToolState;
|
|
211
|
+
output?: string;
|
|
212
|
+
};
|
|
213
|
+
};
|
|
214
|
+
export declare function NmChat(props: {
|
|
215
|
+
turns: readonly NmChatTurn[];
|
|
216
|
+
empty?: {
|
|
217
|
+
title: string;
|
|
218
|
+
description: string;
|
|
219
|
+
};
|
|
220
|
+
streaming?: boolean;
|
|
221
|
+
}): ReactNode;
|
|
222
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
import { Avatar as AvatarPrimitive } from '@base-ui/react/avatar';
|
|
3
|
+
export declare const NM_AVATAR_SIZES: readonly ['sm', 'default', 'lg'];
|
|
4
|
+
export type NmAvatarSize = (typeof NM_AVATAR_SIZES)[number];
|
|
5
|
+
export declare function NmAvatar({ className, size, ...props }: AvatarPrimitive.Root.Props & {
|
|
6
|
+
size?: NmAvatarSize;
|
|
7
|
+
}): import("react").JSX.Element;
|
|
8
|
+
export declare function NmAvatarImage({ className, ...props }: AvatarPrimitive.Image.Props): import("react").JSX.Element;
|
|
9
|
+
export declare function NmAvatarFallback({ className, ...props }: AvatarPrimitive.Fallback.Props): import("react").JSX.Element;
|
|
10
|
+
export declare function NmAvatarBadge({ className, ...props }: ComponentProps<'span'>): import("react").JSX.Element;
|
|
11
|
+
export declare function NmAvatarGroup({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
12
|
+
export declare function NmAvatarGroupCount({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import type { NmDropdownItem } from '../nm-dropdown/nm-dropdown-item';
|
|
3
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
4
|
+
export type NmBarOverflowProps = {
|
|
5
|
+
menuLabel: string;
|
|
6
|
+
items: readonly NmDropdownItem[];
|
|
7
|
+
onSelect: (id: string) => void;
|
|
8
|
+
testId?: string;
|
|
9
|
+
className?: string;
|
|
10
|
+
hiddenOnNarrow?: boolean;
|
|
11
|
+
menuIcon?: NmIconId;
|
|
12
|
+
trailing?: ReactNode;
|
|
13
|
+
children: ReactNode;
|
|
14
|
+
};
|
|
15
|
+
export declare function NmBarOverflow(props: NmBarOverflowProps): ReactNode;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type RefObject } from 'react';
|
|
2
|
+
import { type BarOverflowMode } from '../../lib/bar-overflow.ts';
|
|
3
|
+
export declare function useBarOverflow(rootRef: RefObject<HTMLElement | null>, rowRef: RefObject<HTMLElement | null>): {
|
|
4
|
+
mode: BarOverflowMode;
|
|
5
|
+
open: boolean;
|
|
6
|
+
setOpen: (open: boolean) => void;
|
|
7
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* A brand logo from its SVG source, such as the strings in @thesvg/icons. The markup must come from a trusted
|
|
4
|
+
* package, never from user input. It is drawn at the icon size, and a mono logo (`mono`) takes the text colour, so it reads on any theme.
|
|
5
|
+
*/
|
|
6
|
+
export declare function NmBrandLogo({ svg, label, mono, className, ...props }: Omit<ComponentProps<'span'>, 'children'> & {
|
|
7
|
+
svg: string;
|
|
8
|
+
label?: string;
|
|
9
|
+
mono?: boolean;
|
|
10
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
/** The path to the current page. The shadcn Breadcrumb composition, styled by NIF tokens. */
|
|
3
|
+
export declare function NmBreadcrumb({ className, ...props }: ComponentProps<'nav'>): import("react").JSX.Element;
|
|
4
|
+
export declare function NmBreadcrumbList({ className, ...props }: ComponentProps<'ol'>): import("react").JSX.Element;
|
|
5
|
+
export declare function NmBreadcrumbItem({ className, ...props }: ComponentProps<'li'>): import("react").JSX.Element;
|
|
6
|
+
export declare function NmBreadcrumbLink({ className, ...props }: ComponentProps<'a'>): import("react").JSX.Element;
|
|
7
|
+
/** The current page. It is not a link. */
|
|
8
|
+
export declare function NmBreadcrumbPage({ className, ...props }: ComponentProps<'span'>): import("react").JSX.Element;
|
|
9
|
+
export declare function NmBreadcrumbSeparator({ className, children, ...props }: ComponentProps<'li'>): import("react").JSX.Element;
|
|
10
|
+
/** Stands for the levels left out. Put it in a dropdown menu trigger to let people reach them. */
|
|
11
|
+
export declare function NmBreadcrumbEllipsis({ className, ...props }: ComponentProps<'span'>): import("react").JSX.Element;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
import { NM_BUTTON_SIZES, NM_BUTTON_TONES, type NmButtonSize, type NmButtonTone } from '../../config/nm-button.ts';
|
|
4
|
+
export type NmButtonProps = {
|
|
5
|
+
label: string;
|
|
6
|
+
tone: NmButtonTone;
|
|
7
|
+
size?: NmButtonSize;
|
|
8
|
+
block?: boolean;
|
|
9
|
+
type?: 'button' | 'submit';
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
pressed?: boolean;
|
|
12
|
+
icon?: NmIconId;
|
|
13
|
+
/** Shows the icon alone, in a square. The label is still its accessible name. */
|
|
14
|
+
iconOnly?: boolean;
|
|
15
|
+
testId?: string;
|
|
16
|
+
onClick?: () => void;
|
|
17
|
+
};
|
|
18
|
+
export declare function NmButton(props: NmButtonProps): ReactNode;
|
|
19
|
+
export { NM_BUTTON_SIZES, NM_BUTTON_TONES };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type ComponentProps, type ReactElement } from 'react';
|
|
2
|
+
import { NmSeparator } from '../nm-separator/nm-separator.tsx';
|
|
3
|
+
/**
|
|
4
|
+
* Joins buttons, and the controls that sit beside them, into one bar. Neighbours share a border and only the outer
|
|
5
|
+
* corners stay round. Nest groups to set sets of buttons apart. The shadcn Button Group composition, styled by NIF tokens.
|
|
6
|
+
*/
|
|
7
|
+
export declare function NmButtonGroup({ className, orientation, ...props }: ComponentProps<'div'> & {
|
|
8
|
+
orientation?: 'horizontal' | 'vertical';
|
|
9
|
+
}): import("react").JSX.Element;
|
|
10
|
+
/** A line between buttons that have no border of their own. Outline buttons do not need one. */
|
|
11
|
+
export declare function NmButtonGroupSeparator({ className, orientation, ...props }: ComponentProps<typeof NmSeparator>): import("react").JSX.Element;
|
|
12
|
+
/** Text in the bar, set like a button. Give `render` an element, such as a Label, to draw the text with it. */
|
|
13
|
+
export declare function NmButtonGroupText({ className, render, children, ...props }: ComponentProps<'div'> & {
|
|
14
|
+
render?: ReactElement<{
|
|
15
|
+
className?: string;
|
|
16
|
+
}>;
|
|
17
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { type DayPickerProps } from 'react-day-picker';
|
|
2
|
+
/** react-day-picker, in the shadcn Calendar composition, drawn entirely by NIF tokens. Single, multiple or range. */
|
|
3
|
+
export declare function NmCalendar({ className, showOutsideDays, ...props }: DayPickerProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
export declare const NM_CARD_VARIANTS: readonly ['default', 'outline', 'muted'];
|
|
3
|
+
export declare const NM_CARD_SIZES: readonly ['default', 'sm'];
|
|
4
|
+
export type NmCardVariant = (typeof NM_CARD_VARIANTS)[number];
|
|
5
|
+
export type NmCardSize = (typeof NM_CARD_SIZES)[number];
|
|
6
|
+
type CardOptions = {
|
|
7
|
+
variant?: NmCardVariant;
|
|
8
|
+
size?: NmCardSize;
|
|
9
|
+
/** The card is the person's current choice. */
|
|
10
|
+
selected?: boolean;
|
|
11
|
+
/** The card cannot be used. */
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* A surface that groups related content. The shadcn Card composition, styled by NIF tokens.
|
|
16
|
+
* Give it an `href` and it becomes a link, with hover and focus states.
|
|
17
|
+
*/
|
|
18
|
+
export declare function NmCard({ className, variant, size, selected, disabled, href, ...props }: Omit<ComponentProps<'div'>, 'onClick'> & CardOptions & {
|
|
19
|
+
href?: string;
|
|
20
|
+
onClick?: ComponentProps<'a'>['onClick'];
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
/** `align="center"` centres a leading icon and a trailing action against the text, as in a row of apps. */
|
|
23
|
+
export declare function NmCardHeader({ className, align, ...props }: ComponentProps<'div'> & {
|
|
24
|
+
align?: 'start' | 'center';
|
|
25
|
+
}): import("react").JSX.Element;
|
|
26
|
+
export declare function NmCardTitle({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
27
|
+
export declare function NmCardDescription({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
28
|
+
/** Sits at the end of the header, beside the title. */
|
|
29
|
+
export declare function NmCardAction({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
30
|
+
export declare function NmCardContent({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
31
|
+
export declare function NmCardFooter({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
32
|
+
/** A leading icon or image in the header. The title, description and footer line up beside it. */
|
|
33
|
+
export declare function NmCardMedia({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
34
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import { type NmChatboxIconId } from '../../config/nm-chatbox-icons.ts';
|
|
3
|
+
export declare const NM_CHATBOX_LUCIDE_MAP: Record<NmChatboxIconId, string>;
|
|
4
|
+
export declare function NmChatboxIcon({ id, className, }: {
|
|
5
|
+
id: NmChatboxIconId;
|
|
6
|
+
className?: string;
|
|
7
|
+
}): ReactNode;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
export type NmChatboxProps = {
|
|
3
|
+
placeholder: string;
|
|
4
|
+
placeholderEmphasis?: string;
|
|
5
|
+
value: string;
|
|
6
|
+
sendLabel: string;
|
|
7
|
+
attachLabel: string;
|
|
8
|
+
micLabel: string;
|
|
9
|
+
fieldId?: string;
|
|
10
|
+
micPressed?: boolean;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
testId?: string;
|
|
13
|
+
tools?: ReactNode;
|
|
14
|
+
onChange: (value: string) => void;
|
|
15
|
+
onSend: () => void;
|
|
16
|
+
onAttach?: () => void;
|
|
17
|
+
onMic?: () => void;
|
|
18
|
+
};
|
|
19
|
+
export declare function NmChatbox(props: NmChatboxProps): ReactNode;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import type { ComponentProps, ReactNode } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
export declare const NM_CHIP_TONES: readonly ['neutral', 'outline', 'filled', 'ok', 'warn', 'error'];
|
|
4
|
+
export declare const NM_CHIP_SIZES: readonly ['default', 'sm'];
|
|
5
|
+
export type NmChipTone = (typeof NM_CHIP_TONES)[number];
|
|
6
|
+
export type NmChipSize = (typeof NM_CHIP_SIZES)[number];
|
|
7
|
+
type NmChipBase = {
|
|
8
|
+
tone?: NmChipTone;
|
|
9
|
+
size?: NmChipSize;
|
|
10
|
+
icon?: NmIconId;
|
|
11
|
+
/** A chip that stands for a chosen filter or option. */
|
|
12
|
+
selected?: boolean;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
children: ReactNode;
|
|
15
|
+
className?: string;
|
|
16
|
+
};
|
|
17
|
+
export type NmChipProps = NmChipBase & ({
|
|
18
|
+
onClick?: undefined;
|
|
19
|
+
href?: undefined;
|
|
20
|
+
onRemove?: () => void;
|
|
21
|
+
removeLabel?: string;
|
|
22
|
+
} | {
|
|
23
|
+
onClick: () => void;
|
|
24
|
+
href?: undefined;
|
|
25
|
+
onRemove?: undefined;
|
|
26
|
+
removeLabel?: undefined;
|
|
27
|
+
} | {
|
|
28
|
+
href: string;
|
|
29
|
+
onClick?: undefined;
|
|
30
|
+
onRemove?: undefined;
|
|
31
|
+
removeLabel?: undefined;
|
|
32
|
+
}) & Omit<ComponentProps<'span'>, 'children' | 'className' | 'onClick'>;
|
|
33
|
+
/**
|
|
34
|
+
* A small label for a status, a filter, an attachment or a tag. Static by default. Give it `onClick` and it
|
|
35
|
+
* becomes a button, `href` and it becomes a link, `onRemove` and it gains a remove button.
|
|
36
|
+
*/
|
|
37
|
+
export declare function NmChip({ tone, size, icon, selected, disabled, children, className, onClick, href, onRemove, removeLabel, ...rest }: NmChipProps): import("react").JSX.Element;
|
|
38
|
+
export {};
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { type ComponentProps, type ReactNode } from 'react';
|
|
2
|
+
export declare const NM_CODE_BLOCK_VARIANTS: readonly ['default', 'destructive'];
|
|
3
|
+
export declare const NM_CODE_BLOCK_SIZES: readonly ['default', 'sm'];
|
|
4
|
+
export type NmCodeBlockVariant = (typeof NM_CODE_BLOCK_VARIANTS)[number];
|
|
5
|
+
export type NmCodeBlockSize = (typeof NM_CODE_BLOCK_SIZES)[number];
|
|
6
|
+
/**
|
|
7
|
+
* Displays code, terminal output and diffs with an optional header, line numbers and a copy button.
|
|
8
|
+
* The shadcn Code Block composition, styled by NIF tokens. Colours for syntax come from the --nm-syntax tokens.
|
|
9
|
+
*/
|
|
10
|
+
export declare function NmCodeBlock({ className, variant, size, ...props }: ComponentProps<'div'> & {
|
|
11
|
+
variant?: NmCodeBlockVariant;
|
|
12
|
+
size?: NmCodeBlockSize;
|
|
13
|
+
}): import("react").JSX.Element;
|
|
14
|
+
export declare function NmCodeBlockHeader({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
15
|
+
export declare function NmCodeBlockTitle({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
16
|
+
/** Buttons for the header. Placed straight in the block, they float over its top right corner. */
|
|
17
|
+
export declare function NmCodeBlockActions({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
18
|
+
/** An icon button that copies `value`. It shows a tick for a moment afterwards. */
|
|
19
|
+
export declare function NmCodeBlockCopyButton({ value, label, copiedLabel }: {
|
|
20
|
+
value: string;
|
|
21
|
+
label?: string;
|
|
22
|
+
copiedLabel?: string;
|
|
23
|
+
}): import("react").JSX.Element;
|
|
24
|
+
/** One line. `variant` marks it as highlighted, added or removed. */
|
|
25
|
+
export declare function NmCodeBlockLine({ className, variant, children, html, language, ...props }: Omit<ComponentProps<'span'>, 'children'> & {
|
|
26
|
+
variant?: 'default' | 'highlighted' | 'added' | 'removed';
|
|
27
|
+
children?: ReactNode;
|
|
28
|
+
html?: string;
|
|
29
|
+
language?: NmCodeLanguage;
|
|
30
|
+
}): import("react").JSX.Element;
|
|
31
|
+
/** Splits highlighted markup from shiki into one string per line. */
|
|
32
|
+
export declare function nmHighlightedLines(html: string): string[];
|
|
33
|
+
export declare const NM_CODE_LANGUAGES: readonly ['tsx', 'ts', 'js', 'json', 'css', 'bash'];
|
|
34
|
+
export type NmCodeLanguage = (typeof NM_CODE_LANGUAGES)[number];
|
|
35
|
+
export type NmCodeBlockContentProps = Omit<ComponentProps<'pre'>, 'children'> & {
|
|
36
|
+
/** A string, or a list of NmCodeBlockLine. */
|
|
37
|
+
children?: ReactNode;
|
|
38
|
+
/** Code already highlighted, as shiki writes it. Used in place of children. */
|
|
39
|
+
html?: string;
|
|
40
|
+
/** Colour the code in this language. Use `html` instead for a highlighter of your own. */
|
|
41
|
+
language?: NmCodeLanguage;
|
|
42
|
+
wrap?: boolean;
|
|
43
|
+
lineNumbers?: boolean;
|
|
44
|
+
startLine?: number;
|
|
45
|
+
/** Show only this many lines, dimmed, with a button to show the rest. */
|
|
46
|
+
collapsedLines?: number;
|
|
47
|
+
labels?: {
|
|
48
|
+
show: string;
|
|
49
|
+
hide: string;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
/** The pre that scrolls or wraps. */
|
|
53
|
+
export declare function NmCodeBlockContent({ className, children, html, language, wrap, lineNumbers, startLine, collapsedLines, labels, style, ...props }: NmCodeBlockContentProps): import("react").JSX.Element;
|
|
54
|
+
/** A row under the code, for a note or a button. */
|
|
55
|
+
export declare function NmCodeBlockFooter({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
import { type NmCollectionView } from '../../config/nm-collection.ts';
|
|
4
|
+
export type NmCollectionBarProps = {
|
|
5
|
+
title: string;
|
|
6
|
+
titleSrc: string;
|
|
7
|
+
titleIcon?: NmIconId;
|
|
8
|
+
filterIcon?: NmIconId;
|
|
9
|
+
view: NmCollectionView;
|
|
10
|
+
gridLabel: string;
|
|
11
|
+
tableLabel: string;
|
|
12
|
+
switchLabel: string;
|
|
13
|
+
showSwitch?: boolean;
|
|
14
|
+
onView: (view: NmCollectionView) => void;
|
|
15
|
+
};
|
|
16
|
+
export declare function NmCollectionBar(props: NmCollectionBarProps): ReactNode;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import { type NmCollectionItem, type NmCollectionItemActions } from '../../config/nm-collection.ts';
|
|
3
|
+
export type NmCollectionGridProps = {
|
|
4
|
+
items: readonly NmCollectionItem[];
|
|
5
|
+
label: string;
|
|
6
|
+
actions?: NmCollectionItemActions;
|
|
7
|
+
onSelect: (id: string) => void;
|
|
8
|
+
};
|
|
9
|
+
export declare function NmCollectionGrid(props: NmCollectionGridProps): ReactNode;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
export type NmCollectionQueryProps = {
|
|
3
|
+
imageLabel: string;
|
|
4
|
+
videoLabel: string;
|
|
5
|
+
audioLabel: string;
|
|
6
|
+
searchLabel: string;
|
|
7
|
+
imageOn: boolean;
|
|
8
|
+
videoOn: boolean;
|
|
9
|
+
audioOn: boolean;
|
|
10
|
+
query: string;
|
|
11
|
+
onImage: (on: boolean) => void;
|
|
12
|
+
onVideo: (on: boolean) => void;
|
|
13
|
+
onAudio: (on: boolean) => void;
|
|
14
|
+
onQuery: (query: string) => void;
|
|
15
|
+
filters?: boolean;
|
|
16
|
+
search?: boolean;
|
|
17
|
+
};
|
|
18
|
+
export declare function NmCollectionQuery(props: NmCollectionQueryProps): ReactNode;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
import { type NmCollectionColumn, type NmCollectionItem, type NmCollectionItemActions } from '../../config/nm-collection.ts';
|
|
4
|
+
export type NmCollectionTableProps = {
|
|
5
|
+
items: readonly NmCollectionItem[];
|
|
6
|
+
label: string;
|
|
7
|
+
nameLabel?: string;
|
|
8
|
+
columns?: readonly NmCollectionColumn[];
|
|
9
|
+
headerIcon?: NmIconId;
|
|
10
|
+
actions?: NmCollectionItemActions;
|
|
11
|
+
onSelect: (id: string) => void;
|
|
12
|
+
};
|
|
13
|
+
export declare function NmCollectionTable(props: NmCollectionTableProps): ReactNode;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NmIconId } from '../../config/nm-icons.ts';
|
|
3
|
+
export type NmCollectionTitleProps = {
|
|
4
|
+
/** Accessible name (icon-only; not shown as visible text). */
|
|
5
|
+
title: string;
|
|
6
|
+
titleSrc: string;
|
|
7
|
+
titleIcon?: NmIconId;
|
|
8
|
+
};
|
|
9
|
+
/** Collection header identity chip — icon only, raised background on hover. */
|
|
10
|
+
export declare function NmCollectionTitle(props: NmCollectionTitleProps): ReactNode;
|