@arshad-shah/cynosure 0.1.0 → 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 +9 -8
- package/dist/components/SegmentedControl/SegmentedControl.js +35 -27
- package/dist/components/SegmentedControl/SegmentedControl.js.map +1 -1
- package/dist/styles/app-shell.css +1 -1
- package/dist/styles/generated-css.d.ts +1 -1
- package/dist/styles/generated-css.js +1 -1
- package/dist/styles/generated-css.js.map +1 -1
- package/dist/styles/segmented-control.css +1 -1
- package/dist/styles.css +1 -1
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# Cynosure
|
|
4
4
|
|
|
5
|
-
One small, themeable, accessible UI system
|
|
5
|
+
One small, themeable, accessible UI system, used by all my projects: browser extensions, web apps and sites. Same feel and layout everywhere; each project sets its accent, its scale and any token it needs.
|
|
6
6
|
|
|
7
7
|
- **Tiny and tree-shaken**: one module per component and icon, and one small runtime dependency ([Detent](https://github.com/arshad-shah/detent), for dragging).
|
|
8
8
|
- **Looks identical anywhere**: pages, iframes, extension popups and shadow roots; host CSS can't break it.
|
|
@@ -31,7 +31,7 @@ export const App = () => (
|
|
|
31
31
|
);
|
|
32
32
|
```
|
|
33
33
|
|
|
34
|
-
**
|
|
34
|
+
**Documentation:** https://cynosure.arshadshah.com (every component with live examples, its props and its keyboard behaviour).
|
|
35
35
|
|
|
36
36
|
## Docs
|
|
37
37
|
|
|
@@ -39,6 +39,7 @@ export const App = () => (
|
|
|
39
39
|
| -------------------------------------------------------------- | ------------------------------------------------------------------ |
|
|
40
40
|
| [Theming](docs/theming.md) | Accent, scale, radius, fonts, light and dark, per-component tokens |
|
|
41
41
|
| [Icons](docs/icons.md) | Facet icons, brand marks and how brands allow them to be used |
|
|
42
|
+
| [Accessibility](docs/accessibility.md) | What every component guarantees, and how it is tested |
|
|
42
43
|
| [Without React](docs/without-react.md) | Tokens and icons in Astro pages, static sites and plain TypeScript |
|
|
43
44
|
| [Code editors](docs/code-editors.md) | Code colours for CodeMirror, Monaco, Shiki, Prism and highlight.js |
|
|
44
45
|
| [Build adapters](docs/adapters.md) | The Vite adapter and shadow roots (`styles.inline`) |
|
|
@@ -50,11 +51,11 @@ export const App = () => (
|
|
|
50
51
|
|
|
51
52
|
## Components
|
|
52
53
|
|
|
53
|
-
**Foundations:** ButtonBase, LinkBase, InputBase, FileInputBase, TextAreaBase, ChoiceBase, HiddenValue, DialogBase, Icon (240 Facet icons and 97 brand marks); hooks `useRovingFocus`, `useDismiss`, `useDrag` (pointer dragging through Detent), `useControllableState`.
|
|
54
|
-
**Controls:** Button, IconButton, CopyButton, Link, TextField, NumberField, SearchField, TextArea, Select, Combobox, TagInput, Checkbox, Switch, RadioGroup, SegmentedControl, Slider, DateField, TimeField, ColorField, ColorSwatches, KeyValueEditor, FileDrop, SignaturePad, SelectionFrame, CompareSlider, ThemeToggle.
|
|
55
|
-
**Structure:** AppShell, Stack, Inline, Grid, SideNav, SplitPane, Card, Toolbar, Tabs, Disclosure, Accordion, Tree, SortableList, VirtualList, Calendar, DocumentViewport, PanZoomCanvas, ZoomControls.
|
|
56
|
-
**Overlays:** Tooltip, HoverCard, Popover, FloatingToolbar (`DockedToolbar`), Menu, ContextMenu, Dialog, ProgressOverlay, Sheet, CommandPalette (`useHotkey`), Toast (`Toaster`, `useToast`).
|
|
57
|
-
**Feedback and display:** Notice, EmptyState, ProgressBar, Steps, LoadingDots, Skeleton, DescriptionList, Table, Prose, CodeBlock, Announcer (`useAnnounce`), Badge, Kbd, Field. **Theme:** CynosureTheme, useColorMode, themeInitScript, createTheme.
|
|
58
|
-
**Build:** optional Vite adapter (`@arshad-shah/cynosure/vite`), React-free tokens (`@arshad-shah/cynosure/tokens`) and self-hosted Hanken Grotesk (`fonts/hanken.css`).
|
|
54
|
+
- **Foundations:** ButtonBase, LinkBase, InputBase, FileInputBase, TextAreaBase, ChoiceBase, HiddenValue, DialogBase, Icon (240 Facet icons and 97 brand marks); hooks `useRovingFocus`, `useDismiss`, `useDrag` (pointer dragging through Detent), `useControllableState`.
|
|
55
|
+
- **Controls:** Button, IconButton, CopyButton, Link, TextField, NumberField, SearchField, TextArea, Select, Combobox, TagInput, Checkbox, Switch, RadioGroup, SegmentedControl, Slider, DateField, TimeField, ColorField, ColorSwatches, KeyValueEditor, FileDrop, SignaturePad, SelectionFrame, CompareSlider, ThemeToggle.
|
|
56
|
+
- **Structure:** AppShell, Stack, Inline, Grid, SideNav, SplitPane, Card, Toolbar, Tabs, Disclosure, Accordion, Tree, SortableList, VirtualList, Calendar, DocumentViewport, PanZoomCanvas, ZoomControls.
|
|
57
|
+
- **Overlays:** Tooltip, HoverCard, Popover, FloatingToolbar (`DockedToolbar`), Menu, ContextMenu, Dialog, ProgressOverlay, Sheet, CommandPalette (`useHotkey`), Toast (`Toaster`, `useToast`).
|
|
58
|
+
- **Feedback and display:** Notice, EmptyState, ProgressBar, Steps, LoadingDots, Skeleton, DescriptionList, Table, Prose, CodeBlock, Announcer (`useAnnounce`), Badge, Kbd, Field. **Theme:** CynosureTheme, useColorMode, themeInitScript, createTheme.
|
|
59
|
+
- **Build:** optional Vite adapter (`@arshad-shah/cynosure/vite`), React-free tokens (`@arshad-shah/cynosure/tokens`) and self-hosted Hanken Grotesk (`fonts/hanken.css`).
|
|
59
60
|
|
|
60
61
|
> Status: pre-release (`0.x`), developed on `next`. Releases publish to npm from `main` through GitHub Actions (see [Release](docs/release.md)).
|
|
@@ -1,45 +1,53 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
import { useControllableState as x } from "../../foundations/controllable.js";
|
|
3
|
+
import { Icon as N } from "../../foundations/Icon/Icon.js";
|
|
4
|
+
import { ChoiceBase as j } from "../../foundations/ChoiceBase/ChoiceBase.js";
|
|
5
|
+
import { HiddenValue as k } from "../../foundations/HiddenValue/HiddenValue.js";
|
|
6
|
+
import { useId as I } from "react";
|
|
7
|
+
import { jsx as a, jsxs as t } from "react/jsx-runtime";
|
|
8
|
+
function R({ label: i, options: n, name: u, value: o, defaultValue: s, onChange: v, iconOnly: c = !1, fullWidth: b = !1, disabled: l, size: f = "md", tone: g = "neutral", className: m, style: h }) {
|
|
9
|
+
const r = `cy-seg-${I()}`, [d, $, y] = x(o, s, v);
|
|
10
|
+
return /* @__PURE__ */ t("div", {
|
|
9
11
|
role: "radiogroup",
|
|
10
|
-
"aria-label":
|
|
11
|
-
className: `cy-segmented${
|
|
12
|
-
"data-size":
|
|
13
|
-
"data-tone":
|
|
14
|
-
"data-full":
|
|
15
|
-
"data-icon-only":
|
|
16
|
-
style:
|
|
17
|
-
children:
|
|
18
|
-
|
|
12
|
+
"aria-label": i,
|
|
13
|
+
className: `cy-segmented${m ? ` ${m}` : ""}`,
|
|
14
|
+
"data-size": f,
|
|
15
|
+
"data-tone": g,
|
|
16
|
+
"data-full": b ? "" : void 0,
|
|
17
|
+
"data-icon-only": c ? "" : void 0,
|
|
18
|
+
style: h,
|
|
19
|
+
children: [/* @__PURE__ */ a(k, {
|
|
20
|
+
name: u,
|
|
21
|
+
value: d ?? "",
|
|
22
|
+
disabled: l || d === void 0,
|
|
23
|
+
onReset: () => y(s)
|
|
24
|
+
}), n.map((e) => /* @__PURE__ */ t("label", {
|
|
25
|
+
htmlFor: `${r}-${e.value}`,
|
|
19
26
|
className: "cy-segment",
|
|
20
|
-
"data-disabled":
|
|
27
|
+
"data-disabled": l || e.disabled ? "" : void 0,
|
|
21
28
|
children: [
|
|
22
|
-
/* @__PURE__ */ a(
|
|
23
|
-
id: `${
|
|
29
|
+
/* @__PURE__ */ a(j, {
|
|
30
|
+
id: `${r}-${e.value}`,
|
|
24
31
|
type: "radio",
|
|
25
|
-
name:
|
|
32
|
+
name: r,
|
|
33
|
+
form: "",
|
|
26
34
|
value: e.value,
|
|
27
|
-
disabled:
|
|
35
|
+
disabled: l || e.disabled,
|
|
28
36
|
"aria-label": e.label,
|
|
29
|
-
|
|
30
|
-
onChange: (
|
|
37
|
+
checked: d === e.value,
|
|
38
|
+
onChange: (C) => C.currentTarget.checked && $(e.value)
|
|
31
39
|
}),
|
|
32
|
-
e.icon && /* @__PURE__ */ a(
|
|
33
|
-
!
|
|
40
|
+
e.icon && /* @__PURE__ */ a(N, { icon: e.icon }),
|
|
41
|
+
!c && /* @__PURE__ */ a("span", {
|
|
34
42
|
className: "cy-segment-label",
|
|
35
43
|
children: e.label
|
|
36
44
|
})
|
|
37
45
|
]
|
|
38
|
-
}, e.value))
|
|
46
|
+
}, e.value))]
|
|
39
47
|
});
|
|
40
48
|
}
|
|
41
49
|
export {
|
|
42
|
-
|
|
50
|
+
R as SegmentedControl
|
|
43
51
|
};
|
|
44
52
|
|
|
45
53
|
//# sourceMappingURL=SegmentedControl.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SegmentedControl.js","names":["Icon","ChoiceBase","useId","jsx","jsxs","SegmentedControl","label","options","name","value","defaultValue","onChange","iconOnly","fullWidth","disabled","size","tone","className","style","
|
|
1
|
+
{"version":3,"file":"SegmentedControl.js","names":["useControllableState","Icon","ChoiceBase","HiddenValue","useId","jsx","jsxs","SegmentedControl","label","options","name","value","defaultValue","onChange","iconOnly","fullWidth","disabled","size","tone","className","style","groupName","current","setCurrent","reset","option","e"],"sources":["../../../src/components/SegmentedControl/SegmentedControl.tsx"],"sourcesContent":["import { type CSSProperties, useId } from \"react\";\nimport { ChoiceBase } from \"../../foundations/ChoiceBase/ChoiceBase.js\";\nimport { useControllableState } from \"../../foundations/controllable.js\";\nimport { HiddenValue } from \"../../foundations/HiddenValue/HiddenValue.js\";\nimport { Icon } from \"../../foundations/Icon/Icon.js\";\nimport type { IconData } from \"../../icons/types.js\";\nimport type { Size, Tone } from \"../../tokens/schema.js\";\n\nexport interface SegmentedControlTokens {\n radius: string;\n trackBg: string;\n activeBg: string;\n padding: string;\n}\n\ndeclare module \"../../tokens/schema.js\" {\n interface ComponentTokens {\n segmentedControl: SegmentedControlTokens;\n }\n}\n\nexport interface SegmentOption {\n value: string;\n /** Visible text, and always the accessible name (also for icon-only segments). */\n label: string;\n icon?: IconData;\n disabled?: boolean;\n}\n\nexport interface SegmentedControlProps {\n /** Accessible name of the group. */\n label: string;\n options: SegmentOption[];\n name?: string;\n value?: string;\n defaultValue?: string;\n onChange?: (value: string) => void;\n /** Show icons only; labels stay as accessible names. */\n iconOnly?: boolean;\n fullWidth?: boolean;\n disabled?: boolean;\n size?: Size;\n /** Colour of the active segment's content. */\n tone?: Tone;\n className?: string | undefined;\n /** Layout only. */\n style?: CSSProperties | undefined;\n}\n\n/** A compact single choice (view switchers, modes) on native radios. */\nexport function SegmentedControl({\n label,\n options,\n name,\n value,\n defaultValue,\n onChange,\n iconOnly = false,\n fullWidth = false,\n disabled,\n size = \"md\",\n tone = \"neutral\",\n className,\n style,\n}: SegmentedControlProps) {\n // The radios are grouped under a name of the control's own, never the caller's: two controls given the same\n // `name` (rows of a list, two panels) would otherwise be one native radio group with clashing ids, and choosing in\n // one would clear the other. The caller's `name` submits the value through a hidden field instead.\n const groupName = `cy-seg-${useId()}`;\n const [current, setCurrent, reset] = useControllableState<string, string | undefined>(\n value,\n defaultValue,\n onChange,\n );\n return (\n <div\n role=\"radiogroup\"\n aria-label={label}\n className={`cy-segmented${className ? ` ${className}` : \"\"}`}\n data-size={size}\n data-tone={tone}\n data-full={fullWidth ? \"\" : undefined}\n data-icon-only={iconOnly ? \"\" : undefined}\n style={style}\n >\n {/* Always present, so a form's reset restores the default; it submits only when there is a name and a value. */}\n <HiddenValue\n name={name}\n value={current ?? \"\"}\n disabled={disabled || current === undefined}\n onReset={() => reset(defaultValue)}\n />\n {options.map((option) => (\n <label\n key={option.value}\n htmlFor={`${groupName}-${option.value}`}\n className=\"cy-segment\"\n data-disabled={disabled || option.disabled ? \"\" : undefined}\n >\n <ChoiceBase\n id={`${groupName}-${option.value}`}\n type=\"radio\"\n name={groupName}\n // Belongs to no form: the hidden field above submits the value under the caller's name.\n form=\"\"\n value={option.value}\n disabled={disabled || option.disabled}\n aria-label={option.label}\n checked={current === option.value}\n onChange={(e) => e.currentTarget.checked && setCurrent(option.value)}\n />\n {option.icon && <Icon icon={option.icon} />}\n {!iconOnly && <span className=\"cy-segment-label\">{option.label}</span>}\n </label>\n ))}\n </div>\n );\n}\n"],"mappings":";;;;;;;AAkDA,SAAgBO,EAAiB,EAC/B,OAAAC,GACA,SAAAC,GACA,MAAAC,GACA,OAAAC,GACA,cAAAC,GACA,UAAAC,GACA,UAAAC,IAAW,IACX,WAAAC,IAAY,IACZ,UAAAC,GACA,MAAAC,IAAO,MACP,MAAAC,IAAO,WACP,WAAAC,GACA,OAAAC,EAAA,GACwB;AAIxB,QAAMC,IAAY,UAAUjB,EAAM,CAAA,IAC5B,CAACkB,GAASC,GAAYC,CAAA,IAASxB,EACnCW,GACAC,GACAC,CACF;AACA,SACE,gBAAAP,EAAC,OAAD;AAAA,IACE,MAAK;AAAA,IACL,cAAYE;AAAA,IACZ,WAAW,eAAeW,IAAY,IAAIA,CAAA,KAAc,EAAA;AAAA,IACxD,aAAWF;AAAA,IACX,aAAWC;AAAA,IACX,aAAWH,IAAY,KAAK;AAAA,IAC5B,kBAAgBD,IAAW,KAAK;AAAA,IACzB,OAAAM;AAAA,IART,UAAA,CAWE,gBAAAf,EAACF,GAAD;AAAA,MACQ,MAAAO;AAAA,MACN,OAAOY,KAAW;AAAA,MAClB,UAAUN,KAAYM,MAAY;AAAA,MAClC,SAAA,MAAeE,EAAMZ,CAAY;AAAA,IAClC,CAAA,GACAH,EAAQ,IAAA,CAAKgB,MACZ,gBAAAnB,EAAC,SAAD;AAAA,MAEE,SAAS,GAAGe,CAAA,IAAaI,EAAO,KAAA;AAAA,MAChC,WAAU;AAAA,MACV,iBAAeT,KAAYS,EAAO,WAAW,KAAK;AAAA,MAJpD,UAAA;AAAA,QAME,gBAAApB,EAACH,GAAD;AAAA,UACE,IAAI,GAAGmB,CAAA,IAAaI,EAAO,KAAA;AAAA,UAC3B,MAAK;AAAA,UACL,MAAMJ;AAAA,UAEN,MAAK;AAAA,UACL,OAAOI,EAAO;AAAA,UACd,UAAUT,KAAYS,EAAO;AAAA,UAC7B,cAAYA,EAAO;AAAA,UACnB,SAASH,MAAYG,EAAO;AAAA,UAC5B,UAAA,CAAWC,MAAMA,EAAE,cAAc,WAAWH,EAAWE,EAAO,KAAK;AAAA,QACpE,CAAA;AAAA,QACAA,EAAO,QAAQ,gBAAApB,EAACJ,GAAD,EAAM,MAAMwB,EAAO,KAAO,CAAA;AAAA,QACzC,CAACX,KAAY,gBAAAT,EAAC,QAAD;AAAA,UAAM,WAAU;AAAA,UAAoB,UAAAoB,EAAO;AAAA,QAAY,CAAA;AAAA,MAChE;AAAA,IAnBA,GAAAA,EAAO,KAmBP,CACR,CACE;AAAA,E;AAET"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.cy-app-shell.cy-app-shell{--_line:var(--cy-app-shell-border,var(--cy-color-line));background:var(--cy-color-bg);block-size:100%;min-block-size:0;color:var(--cy-color-ink);font-family:var(--cy-font-sans);font-size:var(--cy-font-size-md);font-weight:var(--cy-font-weight-regular);line-height:var(--cy-font-line-height);letter-spacing:normal;text-transform:none;grid-template:"header header""nav main"minmax(0,1fr)/auto minmax(0,1fr);margin:0;padding:0;display:grid;position:relative;box-sizing:border-box!important;&[data-narrow],&:not([data-nav]){grid-template:"header""main"minmax(0,1fr)/minmax(0,1fr)}&[data-tabs]{grid-template:"header""main"minmax(0,1fr)"tabs"/minmax(0,1fr)}}.cy-app-shell-tabs.cy-app-shell-tabs{min-inline-size:0;border-block-start:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-header-background,var(--cy-color-surface));font-size:inherit;grid-area:tabs;padding-block-end:env(safe-area-inset-bottom,0)}.cy-app-shell-skip.cy-app-shell-skip{z-index:1;padding:var(--cy-space-3) var(--cy-space-5);border-radius:var(--cy-radius-md);background:var(--cy-color-surface-raised);color:var(--cy-color-accent-text);font-size:inherit;font-weight:var(--cy-font-weight-medium);text-decoration:underline;position:absolute;inset-block-start:var(--cy-space-2);inset-inline-start:var(--cy-space-2);&:not(:focus){inline-size:var(--cy-border-width);block-size:var(--cy-border-width);clip-path:inset(50%);white-space:nowrap;padding:0;overflow:hidden}&:focus-visible{outline:var(--cy-border-focus) solid var(--cy-color-ring)}}.cy-app-shell-header.cy-app-shell-header{align-items:center;gap:var(--cy-space-4);min-inline-size:0;min-block-size:calc(var(--cy-control-height-lg) + 2 * var(--cy-space-4));padding:var(--cy-space-4) var(--cy-space-6);border-block-end:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-header-background,var(--cy-color-surface));font-size:inherit;grid-area:header;display:flex}.cy-app-shell-bar.cy-app-shell-bar{align-items:center;gap:var(--cy-space-4);min-inline-size:0;font-size:inherit;flex:1;display:flex}.cy-app-shell-nav.cy-app-shell-nav{border-inline-end:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-nav-background,var(--cy-color-surface));min-block-size:0;font-size:inherit;overscroll-behavior:contain;grid-area:nav;overflow-y:auto}.cy-app-shell-main.cy-app-shell-main{min-block-size:0;min-inline-size:0;font-size:inherit;grid-area:main;display:block;overflow-y:auto;&:focus{outline:none}}.cy-app-shell-drawer.cy-app-shell-drawer{margin-inline:calc(-1 * var(--cy-space-4));font-size:inherit;&>.cy-side-nav{inline-size:auto}}
|
|
1
|
+
.cy-app-shell.cy-app-shell{--_line:var(--cy-app-shell-border,var(--cy-color-line));background:var(--cy-color-bg);block-size:100%;min-block-size:0;color:var(--cy-color-ink);font-family:var(--cy-font-sans);font-size:var(--cy-font-size-md);font-weight:var(--cy-font-weight-regular);line-height:var(--cy-font-line-height);letter-spacing:normal;text-transform:none;grid-template:"header header""nav main"minmax(0,1fr)/auto minmax(0,1fr);margin:0;padding:0;display:grid;position:relative;box-sizing:border-box!important;&[data-narrow],&:not([data-nav]){grid-template:"header""main"minmax(0,1fr)/minmax(0,1fr)}&[data-tabs]{grid-template:"header""main"minmax(0,1fr)"tabs"/minmax(0,1fr)}}.cy-app-shell-tabs.cy-app-shell-tabs{min-inline-size:0;border-block-start:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-header-background,var(--cy-color-surface));font-size:inherit;grid-area:tabs;padding-block-end:env(safe-area-inset-bottom,0)}.cy-app-shell-skip.cy-app-shell-skip{z-index:1;padding:var(--cy-space-3) var(--cy-space-5);border-radius:var(--cy-radius-md);background:var(--cy-color-surface-raised);color:var(--cy-color-accent-text);font-size:inherit;font-weight:var(--cy-font-weight-medium);text-decoration:underline;position:absolute;inset-block-start:var(--cy-space-2);inset-inline-start:var(--cy-space-2);&:not(:focus){inline-size:var(--cy-border-width);block-size:var(--cy-border-width);clip-path:inset(50%);white-space:nowrap;padding:0;overflow:hidden}&:focus-visible{outline:var(--cy-border-focus) solid var(--cy-color-ring)}}.cy-app-shell-header.cy-app-shell-header{align-items:center;gap:var(--cy-space-4);min-inline-size:0;min-block-size:calc(var(--cy-control-height-lg) + 2 * var(--cy-space-4));padding:var(--cy-space-4) var(--cy-space-6);border-block-end:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-header-background,var(--cy-color-surface));font-size:inherit;grid-area:header;display:flex}.cy-app-shell-bar.cy-app-shell-bar{align-items:center;gap:var(--cy-space-4);min-inline-size:0;font-size:inherit;flex:1;display:flex}.cy-app-shell-nav.cy-app-shell-nav{border-inline-end:var(--cy-border-width) solid var(--_line);background:var(--cy-app-shell-nav-background,var(--cy-color-surface));min-block-size:0;font-size:inherit;overscroll-behavior:contain;grid-area:nav;position:relative;overflow-y:auto}.cy-app-shell-main.cy-app-shell-main{min-block-size:0;min-inline-size:0;font-size:inherit;grid-area:main;display:block;position:relative;overflow-y:auto;&:focus{outline:none}}.cy-app-shell-drawer.cy-app-shell-drawer{margin-inline:calc(-1 * var(--cy-space-4));font-size:inherit;&>.cy-side-nav{inline-size:auto}}
|