fulldev-ui 0.12.0 → 0.13.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.
Files changed (130) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/package.json +24 -20
  3. package/public/r/accordion.json +1 -1
  4. package/public/r/alert-dialog.json +1 -1
  5. package/public/r/aspect-ratio.json +23 -0
  6. package/public/r/attachment.json +66 -0
  7. package/public/r/button-group.json +41 -0
  8. package/public/r/carousel.json +8 -8
  9. package/public/r/collapsible.json +1 -1
  10. package/public/r/combobox.json +4 -4
  11. package/public/r/command.json +2 -2
  12. package/public/r/components.json +8 -0
  13. package/public/r/dialog.json +1 -1
  14. package/public/r/doc-1.json +1 -1
  15. package/public/r/drawer.json +109 -0
  16. package/public/r/dropdown-menu.json +1 -1
  17. package/public/r/hover-card.json +2 -2
  18. package/public/r/init.json +1 -1
  19. package/public/r/navigation-menu.json +2 -2
  20. package/public/r/pagination.json +59 -0
  21. package/public/r/popover.json +1 -1
  22. package/public/r/radio-group.json +1 -1
  23. package/public/r/registry.json +414 -24
  24. package/public/r/resizable.json +36 -0
  25. package/public/r/reviews-3.json +1 -1
  26. package/public/r/select.json +1 -1
  27. package/public/r/sheet.json +1 -1
  28. package/public/r/sidebar.json +1 -1
  29. package/public/r/slider.json +2 -2
  30. package/public/r/switch.json +1 -1
  31. package/public/r/tabs.json +1 -1
  32. package/public/r/toast.json +80 -0
  33. package/public/r/toggle-group.json +34 -0
  34. package/public/r/toggle.json +1 -1
  35. package/public/r/tooltip.json +1 -1
  36. package/public/r/typography.json +21 -16
  37. package/registry/init/global.css +2 -0
  38. package/registry.json +375 -24
  39. package/src/components/blocks/doc-1.astro +76 -0
  40. package/src/components/blocks/reviews-3.astro +1 -1
  41. package/src/components/ui/aspect-ratio/aspect-ratio.astro +25 -0
  42. package/src/components/ui/aspect-ratio/index.ts +1 -0
  43. package/src/components/ui/attachment/attachment-action.astro +20 -0
  44. package/src/components/ui/attachment/attachment-actions.astro +20 -0
  45. package/src/components/ui/attachment/attachment-content.astro +20 -0
  46. package/src/components/ui/attachment/attachment-description.astro +20 -0
  47. package/src/components/ui/attachment/attachment-group.astro +20 -0
  48. package/src/components/ui/attachment/attachment-media.astro +36 -0
  49. package/src/components/ui/attachment/attachment-title.astro +20 -0
  50. package/src/components/ui/attachment/attachment-trigger.astro +24 -0
  51. package/src/components/ui/attachment/attachment.astro +52 -0
  52. package/src/components/ui/attachment/index.ts +9 -0
  53. package/src/components/ui/button-group/button-group-separator.astro +29 -0
  54. package/src/components/ui/button-group/button-group-text.astro +20 -0
  55. package/src/components/ui/button-group/button-group-variants.ts +20 -0
  56. package/src/components/ui/button-group/button-group.astro +30 -0
  57. package/src/components/ui/button-group/index.ts +7 -0
  58. package/src/components/ui/carousel/carousel-content.astro +11 -13
  59. package/src/components/ui/carousel/carousel-item.astro +2 -5
  60. package/src/components/ui/carousel/carousel-next.astro +0 -3
  61. package/src/components/ui/carousel/carousel-previous.astro +0 -3
  62. package/src/components/ui/carousel/carousel.astro +19 -219
  63. package/src/components/ui/carousel/index.ts +1 -5
  64. package/src/components/ui/combobox/combobox-input.astro +11 -4
  65. package/src/components/ui/combobox/combobox-trigger.astro +7 -7
  66. package/src/components/ui/drawer/drawer-close.astro +13 -0
  67. package/src/components/ui/drawer/drawer-content.astro +43 -0
  68. package/src/components/ui/drawer/drawer-description.astro +17 -0
  69. package/src/components/ui/drawer/drawer-footer.astro +17 -0
  70. package/src/components/ui/drawer/drawer-header.astro +17 -0
  71. package/src/components/ui/drawer/drawer-indent-background.astro +11 -0
  72. package/src/components/ui/drawer/drawer-indent.astro +11 -0
  73. package/src/components/ui/drawer/drawer-overlay.astro +21 -0
  74. package/src/components/ui/drawer/drawer-popup.astro +36 -0
  75. package/src/components/ui/drawer/drawer-portal.astro +27 -0
  76. package/src/components/ui/drawer/drawer-provider.astro +11 -0
  77. package/src/components/ui/drawer/drawer-swipe-handle.astro +20 -0
  78. package/src/components/ui/drawer/drawer-title.astro +17 -0
  79. package/src/components/ui/drawer/drawer-trigger.astro +21 -0
  80. package/src/components/ui/drawer/drawer-viewport.astro +21 -0
  81. package/src/components/ui/drawer/drawer-virtual-keyboard-provider.astro +11 -0
  82. package/src/components/ui/drawer/drawer.astro +60 -0
  83. package/src/components/ui/drawer/index.ts +28 -0
  84. package/src/components/ui/navigation-menu/navigation-menu.astro +2 -2
  85. package/src/components/ui/pagination/index.ts +7 -0
  86. package/src/components/ui/pagination/pagination-content.astro +17 -0
  87. package/src/components/ui/pagination/pagination-ellipsis.astro +22 -0
  88. package/src/components/ui/pagination/pagination-item.astro +11 -0
  89. package/src/components/ui/pagination/pagination-link.astro +41 -0
  90. package/src/components/ui/pagination/pagination-next.astro +27 -0
  91. package/src/components/ui/pagination/pagination-previous.astro +27 -0
  92. package/src/components/ui/pagination/pagination.astro +19 -0
  93. package/src/components/ui/resizable/index.ts +4 -0
  94. package/src/components/ui/resizable/resizable-handle.astro +32 -0
  95. package/src/components/ui/resizable/resizable-panel.astro +36 -0
  96. package/src/components/ui/resizable/resizable.astro +43 -0
  97. package/src/components/ui/slider/slider.astro +1 -1
  98. package/src/components/ui/toast/index.ts +26 -0
  99. package/src/components/ui/toast/toast-action.astro +25 -0
  100. package/src/components/ui/toast/toast-close.astro +27 -0
  101. package/src/components/ui/toast/toast-content.astro +20 -0
  102. package/src/components/ui/toast/toast-description.astro +18 -0
  103. package/src/components/ui/toast/toast-icon.astro +37 -0
  104. package/src/components/ui/toast/toast-item.astro +28 -0
  105. package/src/components/ui/toast/toast-template.astro +11 -0
  106. package/src/components/ui/toast/toast-title.astro +17 -0
  107. package/src/components/ui/toast/toast-viewport.astro +20 -0
  108. package/src/components/ui/toast/toast.astro +51 -0
  109. package/src/components/ui/toast/toaster.astro +37 -0
  110. package/src/components/ui/toggle-group/index.ts +2 -0
  111. package/src/components/ui/toggle-group/toggle-group-item.astro +44 -0
  112. package/src/components/ui/toggle-group/toggle-group.astro +74 -0
  113. package/src/components/ui/typography/typeset.css +441 -0
  114. package/src/components/ui/typography/typography-a.astro +13 -22
  115. package/src/components/ui/typography/typography-blockquote.astro +4 -23
  116. package/src/components/ui/typography/typography-h1.astro +13 -26
  117. package/src/components/ui/typography/typography-h2.astro +13 -31
  118. package/src/components/ui/typography/typography-h3.astro +9 -26
  119. package/src/components/ui/typography/typography-h4.astro +9 -26
  120. package/src/components/ui/typography/typography-inline-code.astro +8 -27
  121. package/src/components/ui/typography/typography-lead.astro +4 -26
  122. package/src/components/ui/typography/typography-list-item.astro +4 -24
  123. package/src/components/ui/typography/typography-list.astro +10 -40
  124. package/src/components/ui/typography/typography-p.astro +9 -28
  125. package/src/components/ui/typography/typography-table-cell.astro +9 -40
  126. package/src/components/ui/typography/typography-table-head.astro +9 -35
  127. package/src/components/ui/typography/typography-table-row.astro +4 -23
  128. package/src/components/ui/typography/typography-table.astro +8 -28
  129. package/src/components/ui/typography/typography.astro +10 -283
  130. package/src/styles/global.css +2 -0
@@ -0,0 +1,20 @@
1
+ ---
2
+ import type { HTMLAttributes } from "astro/types"
3
+
4
+ import { cn } from "@/lib/utils"
5
+
6
+ type Props = HTMLAttributes<"ol">
7
+
8
+ const { class: className, ...props } = Astro.props
9
+ ---
10
+
11
+ <ol
12
+ data-slot="toast-viewport"
13
+ class={cn(
14
+ "group/toast-viewport pointer-events-none fixed z-50 m-0 h-(--toast-stack-size,0px) w-[min(24rem,calc(100vw-2rem))] list-none p-0 outline-none [--toast-collapsed-peek:0.75rem] [--toast-gap:0.75rem] data-[position=bottom-center]:bottom-4 data-[position=bottom-center]:left-1/2 data-[position=bottom-center]:-translate-x-1/2 data-[position=bottom-left]:bottom-4 data-[position=bottom-left]:left-4 data-[position=bottom-right]:right-4 data-[position=bottom-right]:bottom-4 data-[position=top-center]:top-4 data-[position=top-center]:left-1/2 data-[position=top-center]:-translate-x-1/2 data-[position=top-left]:top-4 data-[position=top-left]:left-4 data-[position=top-right]:top-4 data-[position=top-right]:right-4",
15
+ className
16
+ )}
17
+ {...props}
18
+ >
19
+ <slot />
20
+ </ol>
@@ -0,0 +1,51 @@
1
+ ---
2
+ import type { HTMLAttributes } from "astro/types"
3
+ import type { ToastPosition } from "@data-slot/toast"
4
+
5
+ type Props = HTMLAttributes<"div"> & {
6
+ limit?: number
7
+ duration?: number
8
+ position?: ToastPosition
9
+ pauseOnHover?: boolean
10
+ pauseOnFocus?: boolean
11
+ portal?: boolean
12
+ }
13
+
14
+ const {
15
+ class: className,
16
+ limit,
17
+ duration,
18
+ position,
19
+ pauseOnHover,
20
+ pauseOnFocus,
21
+ portal,
22
+ ...props
23
+ } = Astro.props
24
+ ---
25
+
26
+ <div
27
+ data-slot="toast"
28
+ data-limit={limit}
29
+ data-duration={duration}
30
+ data-position={position}
31
+ data-pause-on-hover={pauseOnHover}
32
+ data-pause-on-focus={pauseOnFocus}
33
+ data-portal={portal}
34
+ class={className}
35
+ {...props}
36
+ >
37
+ <slot />
38
+ </div>
39
+
40
+ <script>
41
+ import { create } from "@data-slot/toast"
42
+
43
+ const controllers: ReturnType<typeof create> = []
44
+ const initialize = () => controllers.push(...create())
45
+ initialize()
46
+ document.addEventListener("astro:page-load", initialize)
47
+ document.addEventListener("astro:before-swap", () => {
48
+ for (const controller of controllers) controller.destroy()
49
+ controllers.length = 0
50
+ })
51
+ </script>
@@ -0,0 +1,37 @@
1
+ ---
2
+ import type { ComponentProps } from "astro/types"
3
+
4
+ import ToastAction from "./toast-action.astro"
5
+ import ToastClose from "./toast-close.astro"
6
+ import ToastContent from "./toast-content.astro"
7
+ import ToastDescription from "./toast-description.astro"
8
+ import ToastIcon from "./toast-icon.astro"
9
+ import ToastItem from "./toast-item.astro"
10
+ import ToastTemplate from "./toast-template.astro"
11
+ import ToastTitle from "./toast-title.astro"
12
+ import ToastViewport from "./toast-viewport.astro"
13
+ import Toast from "./toast.astro"
14
+
15
+ type Props = ComponentProps<typeof Toast> & {
16
+ viewportClass?: string
17
+ }
18
+
19
+ const { viewportClass, ...props } = Astro.props
20
+ ---
21
+
22
+ <Toast {...props}>
23
+ <ToastTemplate>
24
+ <ToastItem>
25
+ <ToastContent>
26
+ <ToastIcon />
27
+ <div class="flex min-w-0 flex-1 flex-col gap-1">
28
+ <ToastTitle />
29
+ <ToastDescription />
30
+ </div>
31
+ <ToastAction />
32
+ <ToastClose />
33
+ </ToastContent>
34
+ </ToastItem>
35
+ </ToastTemplate>
36
+ <ToastViewport class={viewportClass} />
37
+ </Toast>
@@ -0,0 +1,2 @@
1
+ export { default as ToggleGroup } from "./toggle-group.astro"
2
+ export { default as ToggleGroupItem } from "./toggle-group-item.astro"
@@ -0,0 +1,44 @@
1
+ ---
2
+ import type { HTMLAttributes } from "astro/types"
3
+
4
+ import { cn } from "@/lib/utils"
5
+ import {
6
+ toggleVariants,
7
+ type ToggleVariantProps,
8
+ } from "@/components/ui/toggle/toggle-variants"
9
+
10
+ type Props = HTMLAttributes<"button"> &
11
+ ToggleVariantProps & {
12
+ value: string
13
+ disabled?: boolean
14
+ }
15
+
16
+ const {
17
+ class: className,
18
+ value,
19
+ disabled,
20
+ variant = "default",
21
+ size = "default",
22
+ type = "button",
23
+ ...props
24
+ } = Astro.props
25
+ ---
26
+
27
+ <button
28
+ data-slot="toggle-group-item"
29
+ data-value={value}
30
+ data-disabled={disabled ? "" : undefined}
31
+ type={type}
32
+ disabled={disabled}
33
+ aria-pressed="false"
34
+ class={cn(
35
+ "data-[state=on]:bg-muted shrink-0 group-aria-disabled/toggle-group:pointer-events-none group-aria-disabled/toggle-group:opacity-50 focus:z-10 focus-visible:z-10",
36
+ "group-data-[variant=outline]/toggle-group:border-input group-data-[variant=default]/toggle-group:border-0 group-data-[variant=default]/toggle-group:shadow-none group-data-[variant=outline]/toggle-group:border group-data-[variant=outline]/toggle-group:shadow-xs group-data-[variant=default]/toggle-group:data-[state=off]:bg-transparent group-data-[variant=outline]/toggle-group:data-[state=off]:bg-transparent",
37
+ "group-data-[size=default]/toggle-group:h-9 group-data-[size=default]/toggle-group:min-w-9 group-data-[size=default]/toggle-group:px-2.5 group-data-[size=lg]/toggle-group:h-10 group-data-[size=lg]/toggle-group:min-w-10 group-data-[size=lg]/toggle-group:px-2.5 group-data-[size=sm]/toggle-group:h-8 group-data-[size=sm]/toggle-group:min-w-8 group-data-[size=sm]/toggle-group:px-2.5 group-data-[size=default]/toggle-group:has-data-[icon=inline-end]:pr-2 group-data-[size=lg]/toggle-group:has-data-[icon=inline-end]:pr-2 group-data-[size=sm]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[size=default]/toggle-group:has-data-[icon=inline-start]:pl-2 group-data-[size=lg]/toggle-group:has-data-[icon=inline-start]:pl-2 group-data-[size=sm]/toggle-group:has-data-[icon=inline-start]:pl-1.5",
38
+ toggleVariants({ variant, size }),
39
+ className
40
+ )}
41
+ {...props}
42
+ >
43
+ <slot />
44
+ </button>
@@ -0,0 +1,74 @@
1
+ ---
2
+ import type { HTMLAttributes } from "astro/types"
3
+
4
+ import { cn } from "@/lib/utils"
5
+ import type { ToggleVariantProps } from "@/components/ui/toggle/toggle-variants"
6
+
7
+ type Props = HTMLAttributes<"div"> &
8
+ ToggleVariantProps & {
9
+ defaultValue?: string | string[]
10
+ multiple?: boolean
11
+ orientation?: "horizontal" | "vertical"
12
+ loop?: boolean
13
+ disabled?: boolean
14
+ spacing?: number
15
+ }
16
+
17
+ const {
18
+ class: className,
19
+ style,
20
+ defaultValue,
21
+ multiple,
22
+ orientation = "horizontal",
23
+ loop,
24
+ disabled,
25
+ variant,
26
+ size,
27
+ spacing = 2,
28
+ ...props
29
+ } = Astro.props
30
+
31
+ const serializedDefaultValue = Array.isArray(defaultValue)
32
+ ? defaultValue.join(" ")
33
+ : defaultValue
34
+
35
+ const resolvedStyle =
36
+ typeof style === "string"
37
+ ? `--gap: ${spacing}; ${style}`
38
+ : { "--gap": spacing, ...(style ?? {}) }
39
+ ---
40
+
41
+ <div
42
+ data-slot="toggle-group"
43
+ data-default-value={serializedDefaultValue}
44
+ data-multiple={multiple ? "" : undefined}
45
+ data-orientation={orientation}
46
+ data-horizontal={orientation === "horizontal" ? "" : undefined}
47
+ data-vertical={orientation === "vertical" ? "" : undefined}
48
+ data-loop={loop}
49
+ data-disabled={disabled ? "" : undefined}
50
+ data-variant={variant}
51
+ data-size={size}
52
+ data-spacing={spacing}
53
+ style={resolvedStyle}
54
+ class={cn(
55
+ "group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-md data-vertical:flex-col data-vertical:items-stretch data-[spacing=0]:data-[variant=outline]:shadow-xs [&[data-orientation=horizontal][data-spacing='0']>[data-slot=toggle-group-item]:first-child]:rounded-l-md [&[data-orientation=horizontal][data-spacing='0']>[data-slot=toggle-group-item]:last-child]:rounded-r-md [&[data-orientation=horizontal][data-spacing='0'][data-variant=outline]>[data-slot=toggle-group-item]:not(:first-child)]:border-l-0 [&[data-orientation=vertical][data-spacing='0']>[data-slot=toggle-group-item]:first-child]:rounded-t-md [&[data-orientation=vertical][data-spacing='0']>[data-slot=toggle-group-item]:last-child]:rounded-b-md [&[data-orientation=vertical][data-spacing='0'][data-variant=outline]>[data-slot=toggle-group-item]:not(:first-child)]:border-t-0 [&[data-spacing='0']>[data-slot=toggle-group-item]]:rounded-none [&[data-spacing='0']>[data-slot=toggle-group-item]]:px-2 [&[data-spacing='0']>[data-slot=toggle-group-item]]:shadow-none [&[data-spacing='0']>[data-slot=toggle-group-item]:has([data-icon=inline-end])]:pr-1.5 [&[data-spacing='0']>[data-slot=toggle-group-item]:has([data-icon=inline-start])]:pl-1.5",
56
+ className
57
+ )}
58
+ {...props}
59
+ >
60
+ <slot />
61
+ </div>
62
+
63
+ <script>
64
+ import { create } from "@data-slot/toggle-group"
65
+
66
+ const controllers: ReturnType<typeof create> = []
67
+ const initialize = () => controllers.push(...create())
68
+ initialize()
69
+ document.addEventListener("astro:page-load", initialize)
70
+ document.addEventListener("astro:before-swap", () => {
71
+ for (const controller of controllers) controller.destroy()
72
+ controllers.length = 0
73
+ })
74
+ </script>
@@ -0,0 +1,441 @@
1
+ /*
2
+ * shadcn/typeset
3
+ * https://ui.shadcn.com/docs/typeset.
4
+ */
5
+
6
+ @layer components {
7
+ .typeset {
8
+ --typeset-font-body: inherit;
9
+ --typeset-font-heading: var(--font-heading);
10
+ --typeset-font-mono: var(--font-mono);
11
+ --typeset-size: 1em;
12
+ --typeset-leading: 1.75;
13
+ --typeset-flow: 1.25em;
14
+ }
15
+ }
16
+
17
+ @layer components {
18
+ .typeset {
19
+ font-family: var(--typeset-font-body);
20
+ font-size: calc(var(--typeset-size) * 1.125);
21
+ line-height: var(--typeset-leading);
22
+ color: var(--color-foreground, currentColor);
23
+ overflow-wrap: break-word;
24
+ margin-trim: block-start;
25
+
26
+ @media (min-width: 48rem), print {
27
+ font-size: var(--typeset-size);
28
+ }
29
+
30
+ --typeset-muted: var(
31
+ --color-muted-foreground,
32
+ color-mix(in oklab, currentColor 60%, transparent)
33
+ );
34
+ --typeset-rule: var(
35
+ --color-border,
36
+ color-mix(in oklab, currentColor 20%, transparent)
37
+ );
38
+ }
39
+
40
+ .typeset
41
+ *:not(
42
+ :where(
43
+ .not-typeset,
44
+ [data-not-typeset],
45
+ .not-typeset *,
46
+ [data-not-typeset] *
47
+ )
48
+ ) {
49
+ &:where(p) {
50
+ margin-block-start: var(--typeset-flow);
51
+ margin-block-end: 0;
52
+ }
53
+ &:where(h1, h2, h3, h4, h5, h6) {
54
+ color: var(--color-foreground, currentColor);
55
+ font-family: var(--typeset-font-heading);
56
+ font-weight: 600;
57
+ margin-block-end: 0;
58
+ }
59
+ &:where(h1) {
60
+ font-size: 1.75em;
61
+ line-height: 1.3;
62
+ margin-block-start: var(--typeset-flow);
63
+ }
64
+ &:where(h2) {
65
+ font-size: 1.25em;
66
+ line-height: 1.4;
67
+ margin-block-start: calc(var(--typeset-flow) * 1.4);
68
+ }
69
+ &:where(h3) {
70
+ font-size: 1.125em;
71
+ line-height: 1.45;
72
+ margin-block-start: var(--typeset-flow);
73
+ }
74
+ &:where(h4) {
75
+ font-size: 1em;
76
+ line-height: 1.5;
77
+ margin-block-start: var(--typeset-flow);
78
+ }
79
+ &:where(h5) {
80
+ font-size: 0.875em;
81
+ line-height: 1.5;
82
+ font-weight: 500;
83
+ color: var(--typeset-muted);
84
+ margin-block-start: calc(var(--typeset-flow) / 0.875);
85
+ }
86
+ &:where(h6) {
87
+ font-size: 0.8125em;
88
+ line-height: 1.5;
89
+ font-weight: 500;
90
+ letter-spacing: 0.08em;
91
+ text-transform: uppercase;
92
+ color: var(--typeset-muted);
93
+ margin-block-start: calc(var(--typeset-flow) / 0.8125);
94
+ }
95
+ &:where([id]) {
96
+ scroll-margin-block-start: var(--typeset-flow);
97
+ }
98
+ &:where(h1 + *, h2 + *, h3 + *, h4 + *, h5 + *, h6 + *) {
99
+ margin-block-start: 1em;
100
+ }
101
+ &:where(:is(h1, h2, h3, h4) :is(code)) {
102
+ font-size: 0.9em;
103
+ }
104
+ &:where(a) {
105
+ color: inherit;
106
+ font-weight: 500;
107
+ text-decoration-line: underline;
108
+ text-decoration-color: color-mix(in oklab, currentColor 30%, transparent);
109
+ }
110
+ &:where(a:hover) {
111
+ text-decoration-color: currentColor;
112
+ }
113
+ &:where(a:focus-visible) {
114
+ outline: 2px solid var(--color-ring, currentColor);
115
+ outline-offset: 2px;
116
+ border-radius: 0.125em;
117
+ }
118
+ &:where(:is(h1, h2, h3, h4, h5, h6) :is(a)) {
119
+ font-weight: inherit;
120
+ }
121
+ &:where(strong, b) {
122
+ font-weight: 600;
123
+ }
124
+ &:where(:is(h1, h2, h3, h4) :is(strong, b)) {
125
+ font-weight: 600;
126
+ }
127
+ &:where(mark) {
128
+ background-color: color-mix(
129
+ in oklab,
130
+ oklch(0.86 0.17 95) 40%,
131
+ transparent
132
+ );
133
+ color: inherit;
134
+ padding: 0.05em 0.15em;
135
+ border-radius: 0.2em;
136
+ }
137
+ &:where(abbr[title]) {
138
+ text-decoration-line: underline;
139
+ text-decoration-style: dotted;
140
+ text-underline-offset: 0.2em;
141
+ cursor: help;
142
+ }
143
+ &:where(del, s) {
144
+ color: var(--typeset-muted);
145
+ text-decoration-line: line-through;
146
+ }
147
+ &:where(sup, sub) {
148
+ font-size: 0.75em;
149
+ line-height: 0;
150
+ position: relative;
151
+ vertical-align: baseline;
152
+ }
153
+ &:where(sup) {
154
+ top: -0.5em;
155
+ }
156
+ &:where(sub) {
157
+ bottom: -0.25em;
158
+ }
159
+ &:where(sup a) {
160
+ text-decoration-line: none;
161
+ font-weight: 500;
162
+ }
163
+ &:where(ul) {
164
+ list-style-type: disc;
165
+ }
166
+ &:where(ol) {
167
+ list-style-type: decimal;
168
+ }
169
+ &:where(ul ul) {
170
+ list-style-type: circle;
171
+ }
172
+ &:where(ul ul ul) {
173
+ list-style-type: square;
174
+ }
175
+ &:where(ol[type="a" i]) {
176
+ list-style-type: lower-alpha;
177
+ }
178
+ &:where(ol[type="i" i]) {
179
+ list-style-type: lower-roman;
180
+ }
181
+ &:where(ol[type="A" s]) {
182
+ list-style-type: upper-alpha;
183
+ }
184
+ &:where(ol[type="I" s]) {
185
+ list-style-type: upper-roman;
186
+ }
187
+ &:where(ul, ol) {
188
+ margin-block-start: var(--typeset-flow);
189
+ margin-block-end: 0;
190
+ padding-inline-start: 1.5em;
191
+ }
192
+ &:where(li) {
193
+ margin-block-start: 0.5em;
194
+ padding-inline-start: 0.4em;
195
+ }
196
+ &:where(li > p, li > ul, li > ol) {
197
+ margin-block-start: 0.5em;
198
+ }
199
+ &:where(ul > li)::marker,
200
+ &:where(ol > li)::marker {
201
+ color: var(--typeset-muted);
202
+ }
203
+ &:where(ul.contains-task-list) {
204
+ list-style-type: none;
205
+ padding-inline-start: 0.25em;
206
+ }
207
+ &:where(li.task-list-item > input[type="checkbox"]) {
208
+ margin-inline-end: 0.5em;
209
+ vertical-align: -0.1em;
210
+ accent-color: var(--color-primary, currentColor);
211
+ }
212
+ &:where(details) {
213
+ margin-block-start: var(--typeset-flow);
214
+ margin-block-end: 0;
215
+ }
216
+ &:where(summary) {
217
+ cursor: pointer;
218
+ font-weight: 500;
219
+ }
220
+ &:where(summary)::marker {
221
+ color: var(--typeset-muted);
222
+ }
223
+ &:where(kbd) {
224
+ font-family: inherit;
225
+ font-size: 0.85em;
226
+ font-weight: 500;
227
+ border: 1px solid var(--typeset-rule);
228
+ border-block-end-width: 2px;
229
+ border-radius: min(calc(var(--radius, 0.5em) * 0.6), 0.35em);
230
+ padding: 0.0625em 0.35em;
231
+ }
232
+ &:where(dl) {
233
+ margin-block-start: var(--typeset-flow);
234
+ margin-block-end: 0;
235
+ }
236
+ &:where(dt) {
237
+ font-weight: 500;
238
+ margin-block-start: 1em;
239
+ }
240
+ &:where(dt + dt) {
241
+ margin-block-start: 0.25em;
242
+ }
243
+ &:where(dd) {
244
+ margin-block-start: 0.25em;
245
+ margin-inline-start: 0;
246
+ padding-inline-start: 1em;
247
+ color: var(--typeset-muted);
248
+ }
249
+ &:where(:not(pre) > code) {
250
+ background-color: var(
251
+ --color-muted,
252
+ color-mix(in oklab, currentColor 8%, transparent)
253
+ );
254
+ font-family: var(--typeset-font-mono);
255
+ font-size: 0.85em;
256
+ border-radius: min(calc(var(--radius, 0.5em) * 0.6), 0.35em);
257
+ padding: 0.125em 0.3em;
258
+ }
259
+ &:where(pre) {
260
+ background-color: var(
261
+ --color-muted,
262
+ color-mix(in oklab, currentColor 8%, transparent)
263
+ );
264
+ font-family: var(--typeset-font-mono);
265
+ font-size: 0.875em;
266
+ line-height: 1.5;
267
+ tab-size: 2;
268
+ direction: ltr;
269
+ border-radius: var(--radius, 0.5em);
270
+ padding: 0.75em 1em;
271
+ overflow-x: auto;
272
+ margin-block-start: calc(var(--typeset-flow) / 0.875);
273
+ margin-block-end: 0;
274
+ }
275
+ &:where(pre code) {
276
+ background-color: transparent;
277
+ font-family: inherit;
278
+ font-size: inherit;
279
+ padding: 0;
280
+ border-radius: 0;
281
+ }
282
+ &:where(blockquote) {
283
+ border-inline-start: 2px solid var(--typeset-rule);
284
+ padding-inline-start: 1em;
285
+ margin-block-start: var(--typeset-flow);
286
+ margin-block-end: 0;
287
+ margin-inline: 0;
288
+ }
289
+ &:where(hr) {
290
+ border: 0;
291
+ border-block-start: 1px solid var(--typeset-rule);
292
+ margin-block-start: calc(var(--typeset-flow) * 2.4);
293
+ margin-block-end: 0;
294
+ }
295
+ &:where(hr + h1, hr + h2, hr + h3, hr + h4) {
296
+ margin-block-start: var(--typeset-flow);
297
+ }
298
+ &:where(.footnotes, [data-footnotes]) {
299
+ margin-block-start: calc(var(--typeset-flow) * 2);
300
+ border-block-start: 1px solid var(--typeset-rule);
301
+ padding-block-start: var(--typeset-flow);
302
+ font-size: 0.875em;
303
+ color: var(--typeset-muted);
304
+ }
305
+ &:where(math[display="block"]) {
306
+ margin-block-start: var(--typeset-flow);
307
+ margin-block-end: 0;
308
+ overflow-x: auto;
309
+ overflow-y: hidden;
310
+ padding-block: 0.25em;
311
+ }
312
+ &:where(img, video) {
313
+ border-radius: var(--radius, 0.5em);
314
+ max-width: 100%;
315
+ height: auto;
316
+ margin-block-start: var(--typeset-flow);
317
+ margin-block-end: 0;
318
+ }
319
+ &:where(p img) {
320
+ margin-block-start: 0;
321
+ }
322
+ &:where(figure) {
323
+ margin-block-start: var(--typeset-flow);
324
+ margin-block-end: 0;
325
+ margin-inline: 0;
326
+ }
327
+ &:where(figcaption, caption) {
328
+ color: var(--typeset-muted);
329
+ font-size: 0.875em;
330
+ text-align: center;
331
+ margin-block-start: calc(0.75em / 0.875);
332
+ }
333
+ &:where(caption) {
334
+ caption-side: bottom;
335
+ }
336
+ &:where(table) {
337
+ max-width: 100%;
338
+ font-size: 1em;
339
+ line-height: 1.5;
340
+ font-variant-numeric: tabular-nums;
341
+ border-collapse: separate;
342
+ border-spacing: 0;
343
+ border-block-end: 1px solid var(--typeset-rule);
344
+ margin-block-start: var(--typeset-flow);
345
+ margin-block-end: 0;
346
+ }
347
+ &:where(.typeset-scroll) {
348
+ overflow-x: auto;
349
+ margin-block-start: var(--typeset-flow);
350
+ }
351
+ &:where(.typeset-scroll > *) {
352
+ margin-block-start: 0;
353
+ }
354
+ &:where(.typeset-scroll table) {
355
+ width: max-content;
356
+ max-width: none;
357
+ }
358
+ &:where(thead th) {
359
+ font-weight: 500;
360
+ text-align: start;
361
+ white-space: nowrap;
362
+ padding: 0.65em 1em;
363
+ }
364
+ &:where(:is(tbody, tfoot) :is(td, th)) {
365
+ padding: 0.75em 1em;
366
+ text-align: start;
367
+ vertical-align: top;
368
+ border-block-start: 1px solid var(--typeset-rule);
369
+ }
370
+ &:where(tbody th, tfoot th) {
371
+ font-weight: 500;
372
+ }
373
+ &:where(th:first-child, td:first-child) {
374
+ padding-inline-start: 0;
375
+ }
376
+ &:where(th[align="center"], td[align="center"]) {
377
+ text-align: center;
378
+ }
379
+ &:where(th[align="right"], td[align="right"]) {
380
+ text-align: end;
381
+ }
382
+ &:where(li > blockquote, li > table, li > figure) {
383
+ margin-block-start: 0.5em;
384
+ }
385
+ &:where(li > pre) {
386
+ margin-block-start: calc(0.5em / 0.875);
387
+ }
388
+ @media print {
389
+ &:where(pre, table, blockquote, figure) {
390
+ break-inside: avoid;
391
+ }
392
+ &:where(h1, h2, h3, h4) {
393
+ break-after: avoid;
394
+ }
395
+ }
396
+ @media (forced-colors: active) {
397
+ &:where(:not(pre) > code) {
398
+ border: 1px solid;
399
+ }
400
+ }
401
+ }
402
+
403
+ .typeset
404
+ > :where(:first-child):not(
405
+ :where(
406
+ .not-typeset,
407
+ [data-not-typeset],
408
+ .not-typeset *,
409
+ [data-not-typeset] *
410
+ )
411
+ ),
412
+ .typeset
413
+ > :where(:first-child)
414
+ > :where(:first-child):not(
415
+ :where(
416
+ .not-typeset,
417
+ [data-not-typeset],
418
+ .not-typeset *,
419
+ [data-not-typeset] *
420
+ )
421
+ ),
422
+ .typeset
423
+ :where(
424
+ li > :first-child,
425
+ blockquote > :first-child,
426
+ td > :first-child,
427
+ th > :first-child,
428
+ dd > :first-child,
429
+ figure > :first-child,
430
+ figure > picture > img
431
+ ):not(
432
+ :where(
433
+ .not-typeset,
434
+ [data-not-typeset],
435
+ .not-typeset *,
436
+ [data-not-typeset] *
437
+ )
438
+ ) {
439
+ margin-block-start: 0;
440
+ }
441
+ }