@passui/react 0.1.19 → 0.1.20
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 +38 -0
- package/THIRD_PARTY_NOTICES.md +25 -0
- package/dist/types/src/components/accordion/accordion.d.ts +19 -0
- package/dist/types/src/components/aspect-ratio/aspect-ratio.d.ts +7 -0
- package/dist/types/src/components/breadcrumb/breadcrumb.d.ts +16 -0
- package/dist/types/src/components/button/button.d.ts +2 -0
- package/dist/types/src/components/code-block/code-block.d.ts +10 -0
- package/dist/types/src/components/combo-box/combo-box.d.ts +9 -0
- package/dist/types/src/components/command/command.d.ts +18 -0
- package/dist/types/src/components/content-unavailable-view/content-unavailable-view.d.ts +9 -0
- package/dist/types/src/components/context-menu/context-menu-store.d.ts +2 -2
- package/dist/types/src/components/context-menu/menu-reveal.d.ts +3 -8
- package/dist/types/src/components/dialog/dialog-store.d.ts +3 -1
- package/dist/types/src/components/disclosure-group/disclosure-group.d.ts +3 -1
- package/dist/types/src/components/keyboard-shortcut/keyboard-shortcut.d.ts +5 -0
- package/dist/types/src/components/menu/menu.d.ts +1 -1
- package/dist/types/src/components/one-time-code/one-time-code.d.ts +18 -0
- package/dist/types/src/components/picker/picker.d.ts +7 -1
- package/dist/types/src/components/popover/anchored-surface.d.ts +13 -0
- package/dist/types/src/components/popover/popover.d.ts +5 -1
- package/dist/types/src/components/progress-view/progress-view.d.ts +1 -1
- package/dist/types/src/components/progress-view/use-liquid-progress.d.ts +3 -0
- package/dist/types/src/components/radio-group/radio-group.d.ts +17 -0
- package/dist/types/src/components/search-field/expanding-search-field.d.ts +5 -0
- package/dist/types/src/components/search-field/search-field.d.ts +5 -1
- package/dist/types/src/components/sidebar/sidebar.d.ts +3 -2
- package/dist/types/src/components/skeleton/skeleton.d.ts +6 -0
- package/dist/types/src/components/slosh-slider/liquid-step.d.ts +6 -0
- package/dist/types/src/components/slosh-slider/slosh-slider.d.ts +18 -0
- package/dist/types/src/components/stepper/rolling-digit.d.ts +11 -0
- package/dist/types/src/components/text-field/text-field.d.ts +3 -1
- package/dist/types/src/components/wake-slider/wake-slider.d.ts +12 -0
- package/dist/types/src/hooks/use-anchored-disclosure.d.ts +9 -0
- package/dist/types/src/hooks/use-anchored-placement.d.ts +1 -1
- package/dist/types/src/index.d.ts +13 -0
- package/dist/types/src/lib/anchored-placement.d.ts +2 -2
- package/package.json +60 -4
- package/src/components/accordion/accordion.tsx +48 -0
- package/src/components/aspect-ratio/aspect-ratio.tsx +22 -0
- package/src/components/breadcrumb/breadcrumb.tsx +53 -0
- package/src/components/button/button.tsx +5 -1
- package/src/components/code-block/code-block.tsx +41 -0
- package/src/components/combo-box/combo-box.tsx +13 -0
- package/src/components/command/command.tsx +119 -0
- package/src/components/compact-date-picker/compact-date-picker.tsx +40 -84
- package/src/components/compact-time-picker/compact-time-picker.tsx +44 -81
- package/src/components/content-unavailable-view/content-unavailable-view.tsx +37 -0
- package/src/components/context-menu/context-menu-host.tsx +28 -24
- package/src/components/context-menu/context-menu-store.ts +3 -4
- package/src/components/context-menu/menu-reveal.ts +5 -2
- package/src/components/dialog/dialog-host.tsx +13 -7
- package/src/components/dialog/dialog-store.ts +15 -4
- package/src/components/disclosure-group/disclosure-group.tsx +19 -10
- package/src/components/keyboard-shortcut/keyboard-shortcut.tsx +17 -0
- package/src/components/menu/menu.tsx +1 -1
- package/src/components/one-time-code/one-time-code.tsx +168 -0
- package/src/components/picker/picker.tsx +121 -108
- package/src/components/popover/anchored-surface.tsx +223 -0
- package/src/components/popover/popover.tsx +149 -20
- package/src/components/progress-view/progress-view.tsx +6 -1
- package/src/components/progress-view/use-liquid-progress.ts +43 -0
- package/src/components/radio-group/radio-group.tsx +63 -0
- package/src/components/search-field/expanding-search-field.tsx +183 -0
- package/src/components/search-field/search-field.tsx +41 -25
- package/src/components/search-list/search-list.tsx +16 -7
- package/src/components/sidebar/sidebar.tsx +21 -12
- package/src/components/skeleton/skeleton.tsx +19 -0
- package/src/components/slosh-slider/liquid-step.ts +42 -0
- package/src/components/slosh-slider/slosh-slider.tsx +251 -0
- package/src/components/stepper/rolling-digit.tsx +77 -0
- package/src/components/stepper/stepper.tsx +50 -29
- package/src/components/text-field/text-field.tsx +45 -7
- package/src/components/toggle/toggle.tsx +147 -30
- package/src/components/wake-slider/wake-slider.tsx +237 -0
- package/src/hooks/use-anchored-disclosure.ts +23 -0
- package/src/hooks/use-anchored-placement.ts +7 -4
- package/src/icons/icons.tsx +150 -150
- package/src/index.ts +18 -0
- package/src/lib/anchored-placement.ts +7 -3
- package/src/styles/code-block.css +33 -0
- package/src/styles/motion-controls.css +189 -0
- package/src/styles/styles.css +3 -0
package/src/icons/icons.tsx
CHANGED
|
@@ -179,7 +179,7 @@ function icon(svg: IconSvgElement, displayName: string) {
|
|
|
179
179
|
|
|
180
180
|
/** A filled variant for toggled states (hearted, starred). */
|
|
181
181
|
function toggleIcon(svg: IconSvgElement, displayName: string) {
|
|
182
|
-
const Base = icon(svg, displayName)
|
|
182
|
+
const Base = /* @__PURE__ */ icon(svg, displayName)
|
|
183
183
|
const Icon = ({ filled = false, className, ...props }: IconProps & { filled?: boolean }) => (
|
|
184
184
|
<Base className={cn(filled && "[&_path]:fill-current", className)} {...props} />
|
|
185
185
|
)
|
|
@@ -189,156 +189,156 @@ function toggleIcon(svg: IconSvgElement, displayName: string) {
|
|
|
189
189
|
|
|
190
190
|
/** Existing catalog glyphs rendered through PassUI's common icon contract. */
|
|
191
191
|
export const catalogIcons = {
|
|
192
|
-
tap: icon(CatalogTapGlyph, "CatalogTapIcon"),
|
|
193
|
-
settings: icon(CatalogSettingsGlyph, "CatalogSettingsIcon"),
|
|
194
|
-
tag: icon(CatalogTagGlyph, "CatalogTagIcon"),
|
|
195
|
-
input: icon(CatalogInputTextGlyph, "CatalogInputIcon"),
|
|
196
|
-
password: icon(CatalogPasswordGlyph, "CatalogPasswordIcon"),
|
|
197
|
-
search: icon(CatalogSearchGlyph, "CatalogSearchIcon"),
|
|
198
|
-
toggle: icon(CatalogToggleGlyph, "CatalogToggleIcon"),
|
|
199
|
-
columns: icon(CatalogColumnsGlyph, "CatalogColumnsIcon"),
|
|
200
|
-
unfold: icon(CatalogUnfoldGlyph, "CatalogUnfoldIcon"),
|
|
201
|
-
colors: icon(CatalogColorsGlyph, "CatalogColorsIcon"),
|
|
202
|
-
calendar: icon(CatalogCalendarGlyph, "CatalogCalendarIcon"),
|
|
203
|
-
clock: icon(CatalogClockGlyph, "CatalogClockIcon"),
|
|
204
|
-
text: icon(CatalogTextGlyph, "CatalogTextIcon"),
|
|
205
|
-
searchList: icon(CatalogSearchListGlyph, "CatalogSearchListIcon"),
|
|
206
|
-
list: icon(CatalogListGlyph, "CatalogListIcon"),
|
|
207
|
-
label: icon(CatalogLabelGlyph, "CatalogLabelIcon"),
|
|
208
|
-
table: icon(CatalogTableGlyph, "CatalogTableIcon"),
|
|
209
|
-
cards: icon(CatalogCardsGlyph, "CatalogCardsIcon"),
|
|
210
|
-
message: icon(CatalogMessageGlyph, "CatalogMessageIcon"),
|
|
211
|
-
sun: icon(CatalogSunGlyph, "CatalogSunIcon"),
|
|
212
|
-
status: icon(CatalogStatusGlyph, "CatalogStatusIcon"),
|
|
213
|
-
analytics: icon(CatalogAnalyticsGlyph, "CatalogAnalyticsIcon"),
|
|
214
|
-
alert: icon(CatalogAlertGlyph, "CatalogAlertIcon"),
|
|
215
|
-
panel: icon(CatalogPanelGlyph, "CatalogPanelIcon"),
|
|
216
|
-
bubble: icon(CatalogBubbleGlyph, "CatalogBubbleIcon"),
|
|
217
|
-
notification: icon(CatalogNotificationGlyph, "CatalogNotificationIcon"),
|
|
218
|
-
menu: icon(CatalogMenuGlyph, "CatalogMenuIcon"),
|
|
219
|
-
help: icon(CatalogHelpGlyph, "CatalogHelpIcon"),
|
|
220
|
-
translate: icon(CatalogTranslateGlyph, "CatalogTranslateIcon"),
|
|
221
|
-
layoutTop: icon(CatalogLayoutTopGlyph, "CatalogLayoutTopIcon"),
|
|
222
|
-
layoutBottom: icon(CatalogLayoutBottomGlyph, "CatalogLayoutBottomIcon"),
|
|
223
|
-
sidebar: icon(CatalogSidebarGlyph, "CatalogSidebarIcon"),
|
|
224
|
-
browser: icon(CatalogBrowserGlyph, "CatalogBrowserIcon"),
|
|
225
|
-
user: icon(CatalogUserGlyph, "CatalogUserIcon"),
|
|
192
|
+
tap: /* @__PURE__ */ icon(CatalogTapGlyph, "CatalogTapIcon"),
|
|
193
|
+
settings: /* @__PURE__ */ icon(CatalogSettingsGlyph, "CatalogSettingsIcon"),
|
|
194
|
+
tag: /* @__PURE__ */ icon(CatalogTagGlyph, "CatalogTagIcon"),
|
|
195
|
+
input: /* @__PURE__ */ icon(CatalogInputTextGlyph, "CatalogInputIcon"),
|
|
196
|
+
password: /* @__PURE__ */ icon(CatalogPasswordGlyph, "CatalogPasswordIcon"),
|
|
197
|
+
search: /* @__PURE__ */ icon(CatalogSearchGlyph, "CatalogSearchIcon"),
|
|
198
|
+
toggle: /* @__PURE__ */ icon(CatalogToggleGlyph, "CatalogToggleIcon"),
|
|
199
|
+
columns: /* @__PURE__ */ icon(CatalogColumnsGlyph, "CatalogColumnsIcon"),
|
|
200
|
+
unfold: /* @__PURE__ */ icon(CatalogUnfoldGlyph, "CatalogUnfoldIcon"),
|
|
201
|
+
colors: /* @__PURE__ */ icon(CatalogColorsGlyph, "CatalogColorsIcon"),
|
|
202
|
+
calendar: /* @__PURE__ */ icon(CatalogCalendarGlyph, "CatalogCalendarIcon"),
|
|
203
|
+
clock: /* @__PURE__ */ icon(CatalogClockGlyph, "CatalogClockIcon"),
|
|
204
|
+
text: /* @__PURE__ */ icon(CatalogTextGlyph, "CatalogTextIcon"),
|
|
205
|
+
searchList: /* @__PURE__ */ icon(CatalogSearchListGlyph, "CatalogSearchListIcon"),
|
|
206
|
+
list: /* @__PURE__ */ icon(CatalogListGlyph, "CatalogListIcon"),
|
|
207
|
+
label: /* @__PURE__ */ icon(CatalogLabelGlyph, "CatalogLabelIcon"),
|
|
208
|
+
table: /* @__PURE__ */ icon(CatalogTableGlyph, "CatalogTableIcon"),
|
|
209
|
+
cards: /* @__PURE__ */ icon(CatalogCardsGlyph, "CatalogCardsIcon"),
|
|
210
|
+
message: /* @__PURE__ */ icon(CatalogMessageGlyph, "CatalogMessageIcon"),
|
|
211
|
+
sun: /* @__PURE__ */ icon(CatalogSunGlyph, "CatalogSunIcon"),
|
|
212
|
+
status: /* @__PURE__ */ icon(CatalogStatusGlyph, "CatalogStatusIcon"),
|
|
213
|
+
analytics: /* @__PURE__ */ icon(CatalogAnalyticsGlyph, "CatalogAnalyticsIcon"),
|
|
214
|
+
alert: /* @__PURE__ */ icon(CatalogAlertGlyph, "CatalogAlertIcon"),
|
|
215
|
+
panel: /* @__PURE__ */ icon(CatalogPanelGlyph, "CatalogPanelIcon"),
|
|
216
|
+
bubble: /* @__PURE__ */ icon(CatalogBubbleGlyph, "CatalogBubbleIcon"),
|
|
217
|
+
notification: /* @__PURE__ */ icon(CatalogNotificationGlyph, "CatalogNotificationIcon"),
|
|
218
|
+
menu: /* @__PURE__ */ icon(CatalogMenuGlyph, "CatalogMenuIcon"),
|
|
219
|
+
help: /* @__PURE__ */ icon(CatalogHelpGlyph, "CatalogHelpIcon"),
|
|
220
|
+
translate: /* @__PURE__ */ icon(CatalogTranslateGlyph, "CatalogTranslateIcon"),
|
|
221
|
+
layoutTop: /* @__PURE__ */ icon(CatalogLayoutTopGlyph, "CatalogLayoutTopIcon"),
|
|
222
|
+
layoutBottom: /* @__PURE__ */ icon(CatalogLayoutBottomGlyph, "CatalogLayoutBottomIcon"),
|
|
223
|
+
sidebar: /* @__PURE__ */ icon(CatalogSidebarGlyph, "CatalogSidebarIcon"),
|
|
224
|
+
browser: /* @__PURE__ */ icon(CatalogBrowserGlyph, "CatalogBrowserIcon"),
|
|
225
|
+
user: /* @__PURE__ */ icon(CatalogUserGlyph, "CatalogUserIcon"),
|
|
226
226
|
} as const
|
|
227
227
|
|
|
228
|
-
export const NoteIcon = icon(Note01Icon, "NoteIcon")
|
|
229
|
-
export const LanguageIcon = icon(LanguagesIcon, "LanguageIcon")
|
|
230
|
-
export const SignOutIcon = icon(Logout01Icon, "SignOutIcon")
|
|
231
|
-
export const MoreVerticalIcon = icon(MoreVertical, "MoreVerticalIcon")
|
|
232
|
-
export const SendIcon = icon(SentIcon, "SendIcon")
|
|
233
|
-
export const InboxIcon = icon(InboxGlyph, "InboxIcon")
|
|
234
|
-
export const LaptopIcon = icon(LaptopGlyph, "LaptopIcon")
|
|
235
|
-
export const SmartphoneIcon = icon(SmartPhone01Icon, "SmartphoneIcon")
|
|
236
|
-
export const TabletIcon = icon(Tablet01Icon, "TabletIcon")
|
|
237
|
-
export const HomeIcon = icon(Home01Icon, "HomeIcon")
|
|
238
|
-
export const LibraryIcon = icon(LibraryGlyph, "LibraryIcon")
|
|
239
|
-
export const PersonIcon = icon(UserIcon, "PersonIcon")
|
|
240
|
-
export const ChartIcon = icon(Analytics01Icon, "ChartIcon")
|
|
241
|
-
export const SupportIcon = icon(CustomerSupportIcon, "SupportIcon")
|
|
242
|
-
export const KeyIcon = icon(Key01Icon, "KeyIcon")
|
|
243
|
-
export const PasswordIcon = icon(LockPasswordIcon, "PasswordIcon")
|
|
244
|
-
export const JournalIcon = icon(NotebookIcon, "JournalIcon")
|
|
245
|
-
export const PenIcon = icon(PencilEdit02Icon, "PenIcon")
|
|
246
|
-
export const StoryIcon = icon(QuillWrite02Icon, "StoryIcon")
|
|
247
|
-
export const BookIcon = icon(BookOpen01Icon, "BookIcon")
|
|
248
|
-
export const ArticleIcon = icon(Book02Icon, "ArticleIcon")
|
|
249
|
-
export const CanvasIcon = icon(HugeCanvasIcon, "CanvasIcon")
|
|
250
|
-
export const LessonIcon = icon(Mortarboard01Icon, "LessonIcon")
|
|
251
|
-
export const PlanIcon = icon(CheckListIcon, "PlanIcon")
|
|
252
|
-
export const MicIcon = icon(Mic01Icon, "MicIcon")
|
|
253
|
-
export const GlobeIcon = icon(Globe02Icon, "GlobeIcon")
|
|
254
|
-
export const ChecklistIcon = icon(CheckmarkCircle02Icon, "ChecklistIcon")
|
|
255
|
-
export const DrawIcon = icon(PencilIcon, "DrawIcon")
|
|
256
|
-
export const ShareIcon = icon(Share08Icon, "ShareIcon")
|
|
257
|
-
export const SearchIcon = icon(Search01Icon, "SearchIcon")
|
|
258
|
-
export const ChevronLeftIcon = icon(ArrowLeft01Icon, "ChevronLeftIcon")
|
|
259
|
-
export const ChevronRightIcon = icon(ArrowRight01Icon, "ChevronRightIcon")
|
|
260
|
-
export const ChevronUpIcon = icon(ArrowUp01Icon, "ChevronUpIcon")
|
|
261
|
-
export const ChevronDownIcon = icon(ArrowDown01Icon, "ChevronDownIcon")
|
|
262
|
-
export const CloseIcon = icon(Cancel01Icon, "CloseIcon")
|
|
263
|
-
export const MenuIcon = icon(Menu01Icon, "MenuIcon")
|
|
264
|
-
export const ThemingIcon = icon(GuidePaintGlyph, "ThemingIcon")
|
|
265
|
-
export const TypesetIcon = icon(GuideTextGlyph, "TypesetIcon")
|
|
266
|
-
export const LayersIcon = icon(GuideLayersGlyph, "LayersIcon")
|
|
267
|
-
export const UploadIcon = icon(UploadGlyph, "UploadIcon")
|
|
268
|
-
export const AttachIcon = icon(AttachGlyph, "AttachIcon")
|
|
269
|
-
export const PlusIcon = icon(Add01Icon, "PlusIcon")
|
|
270
|
-
export const LinkIcon = icon(Link01Icon, "LinkIcon")
|
|
271
|
-
export const CommentIcon = icon(Comment01Icon, "CommentIcon")
|
|
272
|
-
export const TrashIcon = icon(Delete02Icon, "TrashIcon")
|
|
273
|
-
export const PinIcon = icon(Pin02Icon, "PinIcon")
|
|
274
|
-
export const SidebarIcon = icon(PanelLeftIcon, "SidebarIcon")
|
|
275
|
-
export const SettingsIcon = icon(Settings02Icon, "SettingsIcon")
|
|
276
|
-
export const DragHandleIcon = icon(DragDropVerticalIcon, "DragHandleIcon")
|
|
277
|
-
export const VisibleIcon = icon(ViewIcon, "VisibleIcon")
|
|
278
|
-
export const HiddenIcon = icon(ViewOffSlashIcon, "HiddenIcon")
|
|
279
|
-
export const CheckIcon = icon(Tick02Icon, "CheckIcon")
|
|
280
|
-
export const InvoiceIcon = icon(Invoice03Icon, "InvoiceIcon")
|
|
281
|
-
export const QrCodeGlyph = icon(QrCodeIcon, "QrCodeGlyph")
|
|
282
|
-
export const WalletIcon = icon(Wallet01Icon, "WalletIcon")
|
|
283
|
-
export const ScanCodeIcon = icon(ScanIcon, "ScanCodeIcon")
|
|
284
|
-
export const VerifiedIcon = icon(CheckmarkBadge01Icon, "VerifiedIcon")
|
|
285
|
-
export const WarningIcon = icon(Alert02Icon, "WarningIcon")
|
|
286
|
-
export const PrintIcon = icon(PrinterIcon, "PrintIcon")
|
|
287
|
-
export const ImportIcon = icon(FileImportIcon, "ImportIcon")
|
|
288
|
-
export const DownloadIcon = icon(Download01Icon, "DownloadIcon")
|
|
289
|
-
export const PlayIcon = icon(HugePlayIcon, "PlayIcon")
|
|
290
|
-
export const PauseIcon = icon(HugePauseIcon, "PauseIcon")
|
|
291
|
-
export const SkipBackIcon = icon(GoBackward15SecIcon, "SkipBackIcon")
|
|
292
|
-
export const SkipForwardIcon = icon(GoForward30SecIcon, "SkipForwardIcon")
|
|
293
|
-
export const PreviousTrackIcon = icon(PreviousIcon, "PreviousTrackIcon")
|
|
294
|
-
export const NextTrackIcon = icon(NextIcon, "NextTrackIcon")
|
|
295
|
-
export const HeadphonesIcon = icon(HugeHeadphonesIcon, "HeadphonesIcon")
|
|
296
|
-
export const HighlighterIcon = icon(HugeHighlighterIcon, "HighlighterIcon")
|
|
297
|
-
export const ChaptersIcon = icon(LeftToRightListBulletIcon, "ChaptersIcon")
|
|
298
|
-
export const SleepIcon = icon(Moon02Icon, "SleepIcon")
|
|
299
|
-
export const ExpandIcon = icon(FullScreenIcon, "ExpandIcon")
|
|
300
|
-
export const SparkleIcon = icon(AiMagicIcon, "SparkleIcon")
|
|
301
|
-
export const BellIcon = icon(Notification03Icon, "BellIcon")
|
|
302
|
-
export const BusinessIcon = icon(Store01Icon, "BusinessIcon")
|
|
303
|
-
export const CalendarIcon = icon(Calendar03Icon, "CalendarIcon")
|
|
304
|
-
export const BirthdayIcon = icon(BirthdayCakeIcon, "BirthdayIcon")
|
|
305
|
-
export const AlarmIcon = icon(AlarmClockIcon, "AlarmIcon")
|
|
306
|
-
export const RepeatIcon = icon(HugeRepeatIcon, "RepeatIcon")
|
|
307
|
-
export const UndoIcon = icon(HugeUndoIcon, "UndoIcon")
|
|
308
|
-
export const RedoIcon = icon(HugeRedoIcon, "RedoIcon")
|
|
309
|
-
export const PointerIcon = icon(Cursor01Icon, "PointerIcon")
|
|
310
|
-
export const EraserIcon = icon(Eraser01Icon, "EraserIcon")
|
|
311
|
-
export const TouchIcon = icon(Touch01Icon, "TouchIcon")
|
|
312
|
-
export const BubbleIcon = icon(BubbleChatIcon, "BubbleIcon")
|
|
313
|
-
export const BrushIcon = icon(PaintBrush02Icon, "BrushIcon")
|
|
314
|
-
export const LayoutIcon = icon(LayoutGridIcon, "LayoutIcon")
|
|
315
|
-
export const ZoomIcon = icon(SearchAddIcon, "ZoomIcon")
|
|
316
|
-
export const SelectorIcon = icon(UnfoldMoreIcon, "SelectorIcon")
|
|
317
|
-
export const MoreIcon = icon(MoreHorizontalIcon, "MoreIcon")
|
|
318
|
-
export const PeopleIcon = icon(UserMultipleIcon, "PeopleIcon")
|
|
319
|
-
export const AddPersonIcon = icon(UserAdd01Icon, "AddPersonIcon")
|
|
320
|
-
export const ClockIcon = icon(Clock01Icon, "ClockIcon")
|
|
321
|
-
export const LocationIcon = icon(Location01Icon, "LocationIcon")
|
|
322
|
-
export const TaskIcon = icon(Task01Icon, "TaskIcon")
|
|
323
|
-
export const FolderIcon = icon(Folder01Icon, "FolderIcon")
|
|
324
|
-
export const RecentIcon = icon(Time04Icon, "RecentIcon")
|
|
325
|
-
export const ThumbsUpIcon = toggleIcon(HugeThumbsUpIcon, "ThumbsUpIcon")
|
|
326
|
-
export const HeartIcon = toggleIcon(FavouriteIcon, "HeartIcon")
|
|
327
|
-
export const StarIcon = toggleIcon(HugeStarIcon, "StarIcon")
|
|
228
|
+
export const NoteIcon = /* @__PURE__ */ icon(Note01Icon, "NoteIcon")
|
|
229
|
+
export const LanguageIcon = /* @__PURE__ */ icon(LanguagesIcon, "LanguageIcon")
|
|
230
|
+
export const SignOutIcon = /* @__PURE__ */ icon(Logout01Icon, "SignOutIcon")
|
|
231
|
+
export const MoreVerticalIcon = /* @__PURE__ */ icon(MoreVertical, "MoreVerticalIcon")
|
|
232
|
+
export const SendIcon = /* @__PURE__ */ icon(SentIcon, "SendIcon")
|
|
233
|
+
export const InboxIcon = /* @__PURE__ */ icon(InboxGlyph, "InboxIcon")
|
|
234
|
+
export const LaptopIcon = /* @__PURE__ */ icon(LaptopGlyph, "LaptopIcon")
|
|
235
|
+
export const SmartphoneIcon = /* @__PURE__ */ icon(SmartPhone01Icon, "SmartphoneIcon")
|
|
236
|
+
export const TabletIcon = /* @__PURE__ */ icon(Tablet01Icon, "TabletIcon")
|
|
237
|
+
export const HomeIcon = /* @__PURE__ */ icon(Home01Icon, "HomeIcon")
|
|
238
|
+
export const LibraryIcon = /* @__PURE__ */ icon(LibraryGlyph, "LibraryIcon")
|
|
239
|
+
export const PersonIcon = /* @__PURE__ */ icon(UserIcon, "PersonIcon")
|
|
240
|
+
export const ChartIcon = /* @__PURE__ */ icon(Analytics01Icon, "ChartIcon")
|
|
241
|
+
export const SupportIcon = /* @__PURE__ */ icon(CustomerSupportIcon, "SupportIcon")
|
|
242
|
+
export const KeyIcon = /* @__PURE__ */ icon(Key01Icon, "KeyIcon")
|
|
243
|
+
export const PasswordIcon = /* @__PURE__ */ icon(LockPasswordIcon, "PasswordIcon")
|
|
244
|
+
export const JournalIcon = /* @__PURE__ */ icon(NotebookIcon, "JournalIcon")
|
|
245
|
+
export const PenIcon = /* @__PURE__ */ icon(PencilEdit02Icon, "PenIcon")
|
|
246
|
+
export const StoryIcon = /* @__PURE__ */ icon(QuillWrite02Icon, "StoryIcon")
|
|
247
|
+
export const BookIcon = /* @__PURE__ */ icon(BookOpen01Icon, "BookIcon")
|
|
248
|
+
export const ArticleIcon = /* @__PURE__ */ icon(Book02Icon, "ArticleIcon")
|
|
249
|
+
export const CanvasIcon = /* @__PURE__ */ icon(HugeCanvasIcon, "CanvasIcon")
|
|
250
|
+
export const LessonIcon = /* @__PURE__ */ icon(Mortarboard01Icon, "LessonIcon")
|
|
251
|
+
export const PlanIcon = /* @__PURE__ */ icon(CheckListIcon, "PlanIcon")
|
|
252
|
+
export const MicIcon = /* @__PURE__ */ icon(Mic01Icon, "MicIcon")
|
|
253
|
+
export const GlobeIcon = /* @__PURE__ */ icon(Globe02Icon, "GlobeIcon")
|
|
254
|
+
export const ChecklistIcon = /* @__PURE__ */ icon(CheckmarkCircle02Icon, "ChecklistIcon")
|
|
255
|
+
export const DrawIcon = /* @__PURE__ */ icon(PencilIcon, "DrawIcon")
|
|
256
|
+
export const ShareIcon = /* @__PURE__ */ icon(Share08Icon, "ShareIcon")
|
|
257
|
+
export const SearchIcon = /* @__PURE__ */ icon(Search01Icon, "SearchIcon")
|
|
258
|
+
export const ChevronLeftIcon = /* @__PURE__ */ icon(ArrowLeft01Icon, "ChevronLeftIcon")
|
|
259
|
+
export const ChevronRightIcon = /* @__PURE__ */ icon(ArrowRight01Icon, "ChevronRightIcon")
|
|
260
|
+
export const ChevronUpIcon = /* @__PURE__ */ icon(ArrowUp01Icon, "ChevronUpIcon")
|
|
261
|
+
export const ChevronDownIcon = /* @__PURE__ */ icon(ArrowDown01Icon, "ChevronDownIcon")
|
|
262
|
+
export const CloseIcon = /* @__PURE__ */ icon(Cancel01Icon, "CloseIcon")
|
|
263
|
+
export const MenuIcon = /* @__PURE__ */ icon(Menu01Icon, "MenuIcon")
|
|
264
|
+
export const ThemingIcon = /* @__PURE__ */ icon(GuidePaintGlyph, "ThemingIcon")
|
|
265
|
+
export const TypesetIcon = /* @__PURE__ */ icon(GuideTextGlyph, "TypesetIcon")
|
|
266
|
+
export const LayersIcon = /* @__PURE__ */ icon(GuideLayersGlyph, "LayersIcon")
|
|
267
|
+
export const UploadIcon = /* @__PURE__ */ icon(UploadGlyph, "UploadIcon")
|
|
268
|
+
export const AttachIcon = /* @__PURE__ */ icon(AttachGlyph, "AttachIcon")
|
|
269
|
+
export const PlusIcon = /* @__PURE__ */ icon(Add01Icon, "PlusIcon")
|
|
270
|
+
export const LinkIcon = /* @__PURE__ */ icon(Link01Icon, "LinkIcon")
|
|
271
|
+
export const CommentIcon = /* @__PURE__ */ icon(Comment01Icon, "CommentIcon")
|
|
272
|
+
export const TrashIcon = /* @__PURE__ */ icon(Delete02Icon, "TrashIcon")
|
|
273
|
+
export const PinIcon = /* @__PURE__ */ icon(Pin02Icon, "PinIcon")
|
|
274
|
+
export const SidebarIcon = /* @__PURE__ */ icon(PanelLeftIcon, "SidebarIcon")
|
|
275
|
+
export const SettingsIcon = /* @__PURE__ */ icon(Settings02Icon, "SettingsIcon")
|
|
276
|
+
export const DragHandleIcon = /* @__PURE__ */ icon(DragDropVerticalIcon, "DragHandleIcon")
|
|
277
|
+
export const VisibleIcon = /* @__PURE__ */ icon(ViewIcon, "VisibleIcon")
|
|
278
|
+
export const HiddenIcon = /* @__PURE__ */ icon(ViewOffSlashIcon, "HiddenIcon")
|
|
279
|
+
export const CheckIcon = /* @__PURE__ */ icon(Tick02Icon, "CheckIcon")
|
|
280
|
+
export const InvoiceIcon = /* @__PURE__ */ icon(Invoice03Icon, "InvoiceIcon")
|
|
281
|
+
export const QrCodeGlyph = /* @__PURE__ */ icon(QrCodeIcon, "QrCodeGlyph")
|
|
282
|
+
export const WalletIcon = /* @__PURE__ */ icon(Wallet01Icon, "WalletIcon")
|
|
283
|
+
export const ScanCodeIcon = /* @__PURE__ */ icon(ScanIcon, "ScanCodeIcon")
|
|
284
|
+
export const VerifiedIcon = /* @__PURE__ */ icon(CheckmarkBadge01Icon, "VerifiedIcon")
|
|
285
|
+
export const WarningIcon = /* @__PURE__ */ icon(Alert02Icon, "WarningIcon")
|
|
286
|
+
export const PrintIcon = /* @__PURE__ */ icon(PrinterIcon, "PrintIcon")
|
|
287
|
+
export const ImportIcon = /* @__PURE__ */ icon(FileImportIcon, "ImportIcon")
|
|
288
|
+
export const DownloadIcon = /* @__PURE__ */ icon(Download01Icon, "DownloadIcon")
|
|
289
|
+
export const PlayIcon = /* @__PURE__ */ icon(HugePlayIcon, "PlayIcon")
|
|
290
|
+
export const PauseIcon = /* @__PURE__ */ icon(HugePauseIcon, "PauseIcon")
|
|
291
|
+
export const SkipBackIcon = /* @__PURE__ */ icon(GoBackward15SecIcon, "SkipBackIcon")
|
|
292
|
+
export const SkipForwardIcon = /* @__PURE__ */ icon(GoForward30SecIcon, "SkipForwardIcon")
|
|
293
|
+
export const PreviousTrackIcon = /* @__PURE__ */ icon(PreviousIcon, "PreviousTrackIcon")
|
|
294
|
+
export const NextTrackIcon = /* @__PURE__ */ icon(NextIcon, "NextTrackIcon")
|
|
295
|
+
export const HeadphonesIcon = /* @__PURE__ */ icon(HugeHeadphonesIcon, "HeadphonesIcon")
|
|
296
|
+
export const HighlighterIcon = /* @__PURE__ */ icon(HugeHighlighterIcon, "HighlighterIcon")
|
|
297
|
+
export const ChaptersIcon = /* @__PURE__ */ icon(LeftToRightListBulletIcon, "ChaptersIcon")
|
|
298
|
+
export const SleepIcon = /* @__PURE__ */ icon(Moon02Icon, "SleepIcon")
|
|
299
|
+
export const ExpandIcon = /* @__PURE__ */ icon(FullScreenIcon, "ExpandIcon")
|
|
300
|
+
export const SparkleIcon = /* @__PURE__ */ icon(AiMagicIcon, "SparkleIcon")
|
|
301
|
+
export const BellIcon = /* @__PURE__ */ icon(Notification03Icon, "BellIcon")
|
|
302
|
+
export const BusinessIcon = /* @__PURE__ */ icon(Store01Icon, "BusinessIcon")
|
|
303
|
+
export const CalendarIcon = /* @__PURE__ */ icon(Calendar03Icon, "CalendarIcon")
|
|
304
|
+
export const BirthdayIcon = /* @__PURE__ */ icon(BirthdayCakeIcon, "BirthdayIcon")
|
|
305
|
+
export const AlarmIcon = /* @__PURE__ */ icon(AlarmClockIcon, "AlarmIcon")
|
|
306
|
+
export const RepeatIcon = /* @__PURE__ */ icon(HugeRepeatIcon, "RepeatIcon")
|
|
307
|
+
export const UndoIcon = /* @__PURE__ */ icon(HugeUndoIcon, "UndoIcon")
|
|
308
|
+
export const RedoIcon = /* @__PURE__ */ icon(HugeRedoIcon, "RedoIcon")
|
|
309
|
+
export const PointerIcon = /* @__PURE__ */ icon(Cursor01Icon, "PointerIcon")
|
|
310
|
+
export const EraserIcon = /* @__PURE__ */ icon(Eraser01Icon, "EraserIcon")
|
|
311
|
+
export const TouchIcon = /* @__PURE__ */ icon(Touch01Icon, "TouchIcon")
|
|
312
|
+
export const BubbleIcon = /* @__PURE__ */ icon(BubbleChatIcon, "BubbleIcon")
|
|
313
|
+
export const BrushIcon = /* @__PURE__ */ icon(PaintBrush02Icon, "BrushIcon")
|
|
314
|
+
export const LayoutIcon = /* @__PURE__ */ icon(LayoutGridIcon, "LayoutIcon")
|
|
315
|
+
export const ZoomIcon = /* @__PURE__ */ icon(SearchAddIcon, "ZoomIcon")
|
|
316
|
+
export const SelectorIcon = /* @__PURE__ */ icon(UnfoldMoreIcon, "SelectorIcon")
|
|
317
|
+
export const MoreIcon = /* @__PURE__ */ icon(MoreHorizontalIcon, "MoreIcon")
|
|
318
|
+
export const PeopleIcon = /* @__PURE__ */ icon(UserMultipleIcon, "PeopleIcon")
|
|
319
|
+
export const AddPersonIcon = /* @__PURE__ */ icon(UserAdd01Icon, "AddPersonIcon")
|
|
320
|
+
export const ClockIcon = /* @__PURE__ */ icon(Clock01Icon, "ClockIcon")
|
|
321
|
+
export const LocationIcon = /* @__PURE__ */ icon(Location01Icon, "LocationIcon")
|
|
322
|
+
export const TaskIcon = /* @__PURE__ */ icon(Task01Icon, "TaskIcon")
|
|
323
|
+
export const FolderIcon = /* @__PURE__ */ icon(Folder01Icon, "FolderIcon")
|
|
324
|
+
export const RecentIcon = /* @__PURE__ */ icon(Time04Icon, "RecentIcon")
|
|
325
|
+
export const ThumbsUpIcon = /* @__PURE__ */ toggleIcon(HugeThumbsUpIcon, "ThumbsUpIcon")
|
|
326
|
+
export const HeartIcon = /* @__PURE__ */ toggleIcon(FavouriteIcon, "HeartIcon")
|
|
327
|
+
export const StarIcon = /* @__PURE__ */ toggleIcon(HugeStarIcon, "StarIcon")
|
|
328
328
|
|
|
329
329
|
// Wallet: adding, copying and protecting cards.
|
|
330
|
-
export const CameraIcon = icon(Camera01Icon, "CameraIcon")
|
|
331
|
-
export const CopyIcon = icon(Copy01Icon, "CopyIcon")
|
|
332
|
-
export const LockIcon = icon(LockIconSvg, "LockIcon")
|
|
333
|
-
export const NfcReadIcon = icon(NfcIcon, "NfcReadIcon")
|
|
334
|
-
export const PhotoIcon = icon(Image01Icon, "PhotoIcon")
|
|
335
|
-
export const BookmarkIcon = icon(Bookmark02Icon, "BookmarkIcon")
|
|
336
|
-
export const MailIcon = icon(Mail01Icon, "MailIcon")
|
|
337
|
-
export const ReplyIcon = icon(MailReply01Icon, "ReplyIcon")
|
|
338
|
-
export const ArchiveIcon = icon(Archive01Icon, "ArchiveIcon")
|
|
339
|
-
export const InfoIcon = icon(InformationCircleIcon, "InfoIcon")
|
|
340
|
-
export const AlignCenterIcon = icon(TextAlignCenterIcon, "AlignCenterIcon")
|
|
341
|
-
export const AlignLeftIcon = icon(TextAlignLeftIcon, "AlignLeftIcon")
|
|
342
|
-
export const BoldIcon = icon(TextBoldIcon, "BoldIcon")
|
|
343
|
-
export const ItalicIcon = icon(TextItalicIcon, "ItalicIcon")
|
|
344
|
-
export const UnderlineIcon = icon(TextUnderlineIcon, "UnderlineIcon")
|
|
330
|
+
export const CameraIcon = /* @__PURE__ */ icon(Camera01Icon, "CameraIcon")
|
|
331
|
+
export const CopyIcon = /* @__PURE__ */ icon(Copy01Icon, "CopyIcon")
|
|
332
|
+
export const LockIcon = /* @__PURE__ */ icon(LockIconSvg, "LockIcon")
|
|
333
|
+
export const NfcReadIcon = /* @__PURE__ */ icon(NfcIcon, "NfcReadIcon")
|
|
334
|
+
export const PhotoIcon = /* @__PURE__ */ icon(Image01Icon, "PhotoIcon")
|
|
335
|
+
export const BookmarkIcon = /* @__PURE__ */ icon(Bookmark02Icon, "BookmarkIcon")
|
|
336
|
+
export const MailIcon = /* @__PURE__ */ icon(Mail01Icon, "MailIcon")
|
|
337
|
+
export const ReplyIcon = /* @__PURE__ */ icon(MailReply01Icon, "ReplyIcon")
|
|
338
|
+
export const ArchiveIcon = /* @__PURE__ */ icon(Archive01Icon, "ArchiveIcon")
|
|
339
|
+
export const InfoIcon = /* @__PURE__ */ icon(InformationCircleIcon, "InfoIcon")
|
|
340
|
+
export const AlignCenterIcon = /* @__PURE__ */ icon(TextAlignCenterIcon, "AlignCenterIcon")
|
|
341
|
+
export const AlignLeftIcon = /* @__PURE__ */ icon(TextAlignLeftIcon, "AlignLeftIcon")
|
|
342
|
+
export const BoldIcon = /* @__PURE__ */ icon(TextBoldIcon, "BoldIcon")
|
|
343
|
+
export const ItalicIcon = /* @__PURE__ */ icon(TextItalicIcon, "ItalicIcon")
|
|
344
|
+
export const UnderlineIcon = /* @__PURE__ */ icon(TextUnderlineIcon, "UnderlineIcon")
|
package/src/index.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export * from "./components/button/button"
|
|
2
|
+
export * from "./components/accordion/accordion"
|
|
2
3
|
export * from "./components/text-field/text-field"
|
|
3
4
|
export * from "./components/secure-field/secure-field"
|
|
4
5
|
export * from "./components/text-editor/text-editor"
|
|
@@ -84,3 +85,20 @@ export * from "./hooks/use-visual-viewport"
|
|
|
84
85
|
export { registerFloatingLayer } from "./lib/floating-layers"
|
|
85
86
|
|
|
86
87
|
export * from "./hooks/use-minimize-on-scroll"
|
|
88
|
+
|
|
89
|
+
export * from "./components/code-block/code-block"
|
|
90
|
+
export * from "./components/keyboard-shortcut/keyboard-shortcut"
|
|
91
|
+
export * from "./components/content-unavailable-view/content-unavailable-view"
|
|
92
|
+
export * from "./components/combo-box/combo-box"
|
|
93
|
+
export * from "./components/radio-group/radio-group"
|
|
94
|
+
export * from "./components/breadcrumb/breadcrumb"
|
|
95
|
+
export * from "./components/skeleton/skeleton"
|
|
96
|
+
|
|
97
|
+
export * from "./components/command/command"
|
|
98
|
+
|
|
99
|
+
export * from "./components/slosh-slider/slosh-slider"
|
|
100
|
+
export * from "./components/wake-slider/wake-slider"
|
|
101
|
+
|
|
102
|
+
export * from "./components/one-time-code/one-time-code"
|
|
103
|
+
|
|
104
|
+
export * from "./components/aspect-ratio/aspect-ratio"
|
|
@@ -35,8 +35,10 @@ export function placeInViewport(
|
|
|
35
35
|
{ anchor, viewport, edges }: PlacementFrame,
|
|
36
36
|
width: number,
|
|
37
37
|
needed: number,
|
|
38
|
-
gap = 6
|
|
38
|
+
gap = 6,
|
|
39
|
+
overlap = false
|
|
39
40
|
): AnchoredPlacement {
|
|
41
|
+
if (overlap) gap = anchor.top - anchor.bottom
|
|
40
42
|
const fitted = Math.min(width, viewport.width - edges.left - edges.right)
|
|
41
43
|
const left = Math.min(Math.max(edges.left, anchor.left), viewport.width - fitted - edges.right)
|
|
42
44
|
const roomBelow = viewport.height - anchor.bottom - gap - edges.bottom
|
|
@@ -58,7 +60,8 @@ export function placeAnchored(
|
|
|
58
60
|
anchor: HTMLElement,
|
|
59
61
|
width: number,
|
|
60
62
|
needed: number,
|
|
61
|
-
gap = 6
|
|
63
|
+
gap = 6,
|
|
64
|
+
overlap = false
|
|
62
65
|
): AnchoredPlacement {
|
|
63
66
|
const rect = anchor.getBoundingClientRect()
|
|
64
67
|
const viewport = window.visualViewport
|
|
@@ -77,6 +80,7 @@ export function placeAnchored(
|
|
|
77
80
|
},
|
|
78
81
|
width,
|
|
79
82
|
needed,
|
|
80
|
-
gap
|
|
83
|
+
gap,
|
|
84
|
+
overlap
|
|
81
85
|
)
|
|
82
86
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
@layer components {
|
|
2
|
+
.passui-code-block pre {
|
|
3
|
+
margin: 0;
|
|
4
|
+
padding-block: 1rem;
|
|
5
|
+
padding-inline-end: 1.5rem;
|
|
6
|
+
overflow-x: auto;
|
|
7
|
+
font-family: var(--font-mono);
|
|
8
|
+
font-size: var(--text-footnote);
|
|
9
|
+
line-height: 1.75;
|
|
10
|
+
color: var(--color-label);
|
|
11
|
+
background: transparent !important;
|
|
12
|
+
counter-reset: code-line;
|
|
13
|
+
tab-size: 4;
|
|
14
|
+
}
|
|
15
|
+
.passui-code-block .line { display: inline-block; min-width: 100%; }
|
|
16
|
+
.passui-code-block[data-line-numbers] .line::before {
|
|
17
|
+
counter-increment: code-line;
|
|
18
|
+
content: counter(code-line);
|
|
19
|
+
display: inline-block;
|
|
20
|
+
width: 3rem;
|
|
21
|
+
margin-inline-end: 1.25rem;
|
|
22
|
+
color: var(--color-label-tertiary);
|
|
23
|
+
text-align: end;
|
|
24
|
+
user-select: none;
|
|
25
|
+
}
|
|
26
|
+
.passui-code-block:not([data-line-numbers]) pre { padding-inline-start: 1rem; }
|
|
27
|
+
.passui-code-block .shiki, .passui-code-block .shiki span { color: var(--shiki-light); background: transparent !important; }
|
|
28
|
+
@media (prefers-color-scheme: dark) {
|
|
29
|
+
.passui-code-block .shiki, .passui-code-block .shiki span { color: var(--shiki-dark); }
|
|
30
|
+
}
|
|
31
|
+
[data-theme="light"] .passui-code-block .shiki, [data-theme="light"] .passui-code-block .shiki span { color: var(--shiki-light); }
|
|
32
|
+
[data-theme="dark"] .passui-code-block .shiki, [data-theme="dark"] .passui-code-block .shiki span { color: var(--shiki-dark); }
|
|
33
|
+
}
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
/* Slosh and Wake adapted from Bencho; see THIRD_PARTY_NOTICES.md.
|
|
2
|
+
Bencho ink/fill-on map to label; board/fill-slab to elevated; bg to
|
|
3
|
+
background; pane-edge to separator; font-ui to font-sans. Color mixes
|
|
4
|
+
replace rgba RGB triples, so no Bencho variables or new globals leak. */
|
|
5
|
+
@layer components {
|
|
6
|
+
.passui-search-pill { transition: scale 90ms ease; }
|
|
7
|
+
.passui-search-pill:active { scale: 0.98; }
|
|
8
|
+
/* The outline stays whole; its legend opens a real gap under the label.
|
|
9
|
+
No painted background patch needs to match the field's surroundings. */
|
|
10
|
+
.passui-field-outline {
|
|
11
|
+
position: absolute;
|
|
12
|
+
inset: -0.45em 0 0;
|
|
13
|
+
min-width: 0;
|
|
14
|
+
margin: 0;
|
|
15
|
+
padding: 0 0.5rem;
|
|
16
|
+
border: 1px solid var(--color-separator);
|
|
17
|
+
border-radius: inherit;
|
|
18
|
+
pointer-events: none;
|
|
19
|
+
transition: border-color 200ms ease;
|
|
20
|
+
}
|
|
21
|
+
.passui-field-outline legend {
|
|
22
|
+
max-width: 0;
|
|
23
|
+
overflow: hidden;
|
|
24
|
+
padding: 0;
|
|
25
|
+
font-size: var(--text-footnote);
|
|
26
|
+
white-space: nowrap;
|
|
27
|
+
visibility: hidden;
|
|
28
|
+
transition: max-width 320ms ease, padding 320ms ease;
|
|
29
|
+
}
|
|
30
|
+
.passui-floating-label {
|
|
31
|
+
position: absolute;
|
|
32
|
+
inset-inline-start: 0.75rem;
|
|
33
|
+
top: 50%;
|
|
34
|
+
z-index: 1;
|
|
35
|
+
max-width: calc(100% - 1.5rem);
|
|
36
|
+
overflow: hidden;
|
|
37
|
+
text-overflow: ellipsis;
|
|
38
|
+
white-space: nowrap;
|
|
39
|
+
color: var(--color-label-secondary);
|
|
40
|
+
font-size: var(--text-body);
|
|
41
|
+
transform: translateY(-50%);
|
|
42
|
+
transform-origin: left center;
|
|
43
|
+
transition: top 320ms ease, transform 320ms ease, color 200ms ease;
|
|
44
|
+
pointer-events: none;
|
|
45
|
+
}
|
|
46
|
+
.passui-floating-label:dir(rtl) { transform-origin: right center; }
|
|
47
|
+
.passui-floating-label-with-icon { inset-inline-start: 2.5rem; }
|
|
48
|
+
.passui-floating-field input::placeholder { opacity: 0; }
|
|
49
|
+
.passui-floating-field:focus-within input::placeholder { opacity: 1; }
|
|
50
|
+
.passui-floating-field:focus-within .passui-field-outline { border-color: var(--color-label); }
|
|
51
|
+
.passui-floating-field:has(input[aria-invalid="true"]) .passui-field-outline { border-color: var(--color-danger); }
|
|
52
|
+
.passui-floating-field:is(:focus-within, :has(input:not(:placeholder-shown))) .passui-floating-label {
|
|
53
|
+
top: 0;
|
|
54
|
+
inset-inline-start: 0.75rem;
|
|
55
|
+
transform: translateY(-50%) scale(0.78);
|
|
56
|
+
color: var(--color-label);
|
|
57
|
+
}
|
|
58
|
+
.passui-floating-field:is(:focus-within, :has(input:not(:placeholder-shown))) legend {
|
|
59
|
+
max-width: 100%;
|
|
60
|
+
padding-inline: 0.25rem;
|
|
61
|
+
}
|
|
62
|
+
.passui-one-time-code { width: 100%; max-width: calc(var(--otp-length) * 2.5rem + (var(--otp-length) - 1) * 0.5rem); }
|
|
63
|
+
.passui-otp-row { position: relative; height: 3rem; }
|
|
64
|
+
.passui-otp-materials, .passui-otp-digits { display: flex; position: absolute; inset: 0; gap: 0.5rem; pointer-events: none; }
|
|
65
|
+
.passui-otp-cell, .passui-otp-digit { flex: 1; min-width: 0; border-radius: var(--radius-xl); }
|
|
66
|
+
.passui-otp-cell {
|
|
67
|
+
background: var(--color-fill);
|
|
68
|
+
transition: transform 560ms cubic-bezier(0.22, 1, 0.36, 1), background-color 200ms;
|
|
69
|
+
}
|
|
70
|
+
.passui-otp-digit { display: grid; place-items: center; font-size: var(--text-title3); color: var(--color-label); font-variant-numeric: tabular-nums; }
|
|
71
|
+
.passui-otp-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: text; }
|
|
72
|
+
.passui-one-time-code:focus-within .passui-otp-digit[data-active] { box-shadow: inset 0 0 0 2px var(--color-accent-text); }
|
|
73
|
+
.passui-otp-glyph { animation: passui-otp-in 200ms ease-out both; }
|
|
74
|
+
@keyframes passui-otp-in { from { transform: translateY(45%) scale(0.86); opacity: 0; filter: blur(3px); } }
|
|
75
|
+
.passui-otp-capsule { position: absolute; inset-block: 0; left: 50%; width: 60%; border-radius: var(--radius-full); background: var(--color-accent); transform: translateX(-50%) scaleX(0); opacity: 0; transition: transform 560ms cubic-bezier(0.22, 1, 0.36, 1), opacity 160ms; }
|
|
76
|
+
.passui-one-time-code:is([data-status="verifying"], [data-status="success"]) .passui-otp-cell { transform: translateX(calc((var(--otp-middle) - var(--otp-index)) * (100% + 0.5rem))); background: var(--color-accent); }
|
|
77
|
+
.passui-one-time-code:is([data-status="verifying"], [data-status="success"]) .passui-otp-capsule { opacity: 1; transform: translateX(-50%) scaleX(1); }
|
|
78
|
+
.passui-one-time-code:is([data-status="verifying"], [data-status="success"]) .passui-otp-digits { opacity: 0; }
|
|
79
|
+
.passui-otp-check { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); color: var(--color-on-accent); opacity: 0; pointer-events: none; }
|
|
80
|
+
.passui-one-time-code[data-status="success"] .passui-otp-check { opacity: 1; transition: opacity 160ms 240ms; }
|
|
81
|
+
/* A wrong code shivers, then drains right to left. Selecting the single
|
|
82
|
+
input afterward lets the next keystroke replace it without a trap. */
|
|
83
|
+
.passui-one-time-code[data-status="error"] .passui-otp-digit { animation: passui-otp-shiver 380ms ease-out; }
|
|
84
|
+
.passui-one-time-code[data-status="error"] .passui-otp-glyph { animation: passui-otp-drain 220ms calc(380ms + (var(--otp-length) - var(--otp-index)) * 35ms) both; }
|
|
85
|
+
@keyframes passui-otp-shiver { 20% { transform: translateX(4px); } 40% { transform: translateX(-3px); } 60% { transform: translateX(2px); } 80% { transform: translateX(-1px); } }
|
|
86
|
+
@keyframes passui-otp-drain { to { transform: translateY(65%); opacity: 0; filter: blur(3px); } }
|
|
87
|
+
.passui-progress-fill {
|
|
88
|
+
clip-path: polygon(0 0, calc(100% + var(--progress-lean, 0px)) 0,
|
|
89
|
+
calc(100% - var(--progress-lean, 0px)) 100%, 0 100%);
|
|
90
|
+
}
|
|
91
|
+
.passui-slosh-slider {
|
|
92
|
+
width: 100%;
|
|
93
|
+
min-width: 0;
|
|
94
|
+
font-family: var(--font-sans);
|
|
95
|
+
color: var(--color-label);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/* No transitions: every geometry value is written by the loop, and
|
|
99
|
+
a transition on top of a spring is two opinions about one number. */
|
|
100
|
+
.passui-slosh-track {
|
|
101
|
+
position: relative;
|
|
102
|
+
height: 2.5rem;
|
|
103
|
+
border-radius: var(--slosh-radius, var(--radius-full));
|
|
104
|
+
/* Opaque, mixed from the surface's own pair. A translucent wash
|
|
105
|
+
changes with the stage behind it and can disappear in dark mode. */
|
|
106
|
+
background: color-mix(in srgb, var(--color-label) 11%, var(--color-elevated));
|
|
107
|
+
overflow: hidden;
|
|
108
|
+
cursor: ew-resize;
|
|
109
|
+
touch-action: pan-y;
|
|
110
|
+
}
|
|
111
|
+
.passui-slosh-track[aria-disabled="true"],
|
|
112
|
+
.passui-wake-track[aria-disabled="true"] { cursor: not-allowed; }
|
|
113
|
+
.passui-slosh-track:focus-visible,
|
|
114
|
+
.passui-wake-track:focus-visible {
|
|
115
|
+
outline: 2px solid var(--color-accent-text);
|
|
116
|
+
outline-offset: 4px;
|
|
117
|
+
}
|
|
118
|
+
.passui-slosh-fill {
|
|
119
|
+
position: absolute;
|
|
120
|
+
inset-block: 0;
|
|
121
|
+
inset-inline-start: 0;
|
|
122
|
+
background: light-dark(var(--color-elevated), color-mix(in srgb, var(--color-label) 15%, var(--color-elevated)));
|
|
123
|
+
/* Clipped, never skewed: a skew lifts the whole body off the floor;
|
|
124
|
+
a meniscus leans only the moving edge. The track clips end stops. */
|
|
125
|
+
clip-path: polygon(0 0, calc(100% + var(--slosh-lean, 0px)) 0,
|
|
126
|
+
calc(100% - var(--slosh-lean, 0px)) 100%, 0 100%);
|
|
127
|
+
}
|
|
128
|
+
.passui-slosh-track:dir(rtl) .passui-slosh-fill { transform: scaleX(-1); }
|
|
129
|
+
.passui-slosh-knob {
|
|
130
|
+
position: absolute;
|
|
131
|
+
top: 6px;
|
|
132
|
+
bottom: 6px;
|
|
133
|
+
width: 3px;
|
|
134
|
+
margin-inline-start: -1.5px;
|
|
135
|
+
border-radius: var(--radius-full);
|
|
136
|
+
background: var(--color-label);
|
|
137
|
+
pointer-events: none;
|
|
138
|
+
}
|
|
139
|
+
/* Each bar holds energy. Its height is written directly, while React
|
|
140
|
+
owns the value and lit marks. No standing animation runs at rest. */
|
|
141
|
+
.passui-wake-slider {
|
|
142
|
+
display: flex;
|
|
143
|
+
align-items: center;
|
|
144
|
+
gap: 1rem;
|
|
145
|
+
width: 100%;
|
|
146
|
+
min-width: 0;
|
|
147
|
+
color: var(--color-label);
|
|
148
|
+
}
|
|
149
|
+
.passui-wake-track {
|
|
150
|
+
display: flex;
|
|
151
|
+
flex: 1;
|
|
152
|
+
min-width: 0;
|
|
153
|
+
align-items: center;
|
|
154
|
+
justify-content: space-between;
|
|
155
|
+
gap: min(4px, calc(25% / var(--wake-bars, 36)));
|
|
156
|
+
cursor: ew-resize;
|
|
157
|
+
touch-action: pan-y;
|
|
158
|
+
user-select: none;
|
|
159
|
+
-webkit-user-select: none;
|
|
160
|
+
-webkit-tap-highlight-color: transparent;
|
|
161
|
+
border-radius: var(--radius-sm);
|
|
162
|
+
}
|
|
163
|
+
.passui-wake-bar {
|
|
164
|
+
flex: 1 1 3px;
|
|
165
|
+
max-width: 3px;
|
|
166
|
+
min-width: 0;
|
|
167
|
+
border-radius: var(--radius-full);
|
|
168
|
+
background: color-mix(in srgb, var(--color-label) 24%, var(--color-elevated));
|
|
169
|
+
transform-origin: 50% 50%;
|
|
170
|
+
transition: background-color 160ms ease;
|
|
171
|
+
}
|
|
172
|
+
.passui-wake-bar[data-on] { background: var(--color-label); }
|
|
173
|
+
.passui-wake-value {
|
|
174
|
+
min-width: 3ch;
|
|
175
|
+
font-family: var(--font-sans);
|
|
176
|
+
font-size: var(--text-footnote);
|
|
177
|
+
font-weight: 500;
|
|
178
|
+
font-variant-numeric: tabular-nums;
|
|
179
|
+
color: var(--color-label-secondary);
|
|
180
|
+
}
|
|
181
|
+
@media (prefers-reduced-motion: reduce) {
|
|
182
|
+
.passui-wake-bar, .passui-search-pill { transition: none; }
|
|
183
|
+
.passui-search-pill:active { scale: 1; }
|
|
184
|
+
.passui-floating-label, .passui-field-outline, .passui-field-outline legend,
|
|
185
|
+
.passui-otp-cell, .passui-otp-capsule, .passui-otp-check { transition: none; }
|
|
186
|
+
.passui-otp-glyph, .passui-otp-digit { animation: none !important; }
|
|
187
|
+
.passui-otp-materials { filter: none !important; }
|
|
188
|
+
}
|
|
189
|
+
}
|