bestax-mcp 1.18.28 → 1.18.30
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/data/bulma-classes.json +2 -0
- package/data/catalog.json +71 -1
- package/data/components/Affix.json +135 -0
- package/data/components/AppFrame.json +631 -0
- package/data/components/Navbar.json +2 -2
- package/data/skills/bestax-custom-component/references/component-catalog.md +3 -1
- package/data/skills/bestax-layout-scaffold/SKILL.md +22 -3
- package/data/skills/bestax-layout-scaffold/examples/app-shell.tsx +50 -65
- package/data/skills/bestax-layout-scaffold/references/archetypes.md +35 -48
- package/data/skills/bestax-layout-scaffold/references/layout-components.md +30 -0
- package/data/skills/bestax-migrate/references/bloomer/prop-map.md +1 -1
- package/data/skills/bestax-migrate/references/rbx/prop-map.md +1 -1
- package/data/skills/bestax-migrate/references/react-bulma-components/unmappables.md +1 -1
- package/data/skills/bestax-optimize/references/modular-build.md +5 -4
- package/data/skills/bestax-theming/references/css-variables.md +28 -0
- package/data/skills/bestax-theming/references/themeable-components.md +2 -0
- package/data/skills.json +10 -10
- package/package.json +2 -2
package/data/bulma-classes.json
CHANGED
|
@@ -13094,6 +13094,8 @@
|
|
|
13094
13094
|
}
|
|
13095
13095
|
],
|
|
13096
13096
|
"ownClasses": {
|
|
13097
|
+
"affix": "Affix",
|
|
13098
|
+
"app-frame": "AppFrame",
|
|
13097
13099
|
"autocomplete": "Autocomplete",
|
|
13098
13100
|
"avatar": "Avatar",
|
|
13099
13101
|
"avatars": "Avatars",
|
package/data/catalog.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"schemaVersion": 2,
|
|
3
3
|
"generatedFrom": {
|
|
4
4
|
"package": "@allxsmith/bestax-bulma",
|
|
5
|
-
"version": "5.
|
|
5
|
+
"version": "5.61.0"
|
|
6
6
|
},
|
|
7
7
|
"docsBase": "https://bestax.io/docs",
|
|
8
8
|
"categories": [
|
|
@@ -54,6 +54,7 @@
|
|
|
54
54
|
"id": "components",
|
|
55
55
|
"label": "Components",
|
|
56
56
|
"components": [
|
|
57
|
+
"Affix",
|
|
57
58
|
"Avatar",
|
|
58
59
|
"Avatars",
|
|
59
60
|
"Badge",
|
|
@@ -133,6 +134,7 @@
|
|
|
133
134
|
"id": "layout",
|
|
134
135
|
"label": "Layout",
|
|
135
136
|
"components": [
|
|
137
|
+
"AppFrame",
|
|
136
138
|
"Center",
|
|
137
139
|
"Container",
|
|
138
140
|
"Flex",
|
|
@@ -164,6 +166,28 @@
|
|
|
164
166
|
}
|
|
165
167
|
],
|
|
166
168
|
"components": [
|
|
169
|
+
{
|
|
170
|
+
"name": "Affix",
|
|
171
|
+
"kind": "component",
|
|
172
|
+
"category": "components",
|
|
173
|
+
"purpose": "The `Affix` component keeps its content fixed to a corner of the viewport while the page scrolls under it.",
|
|
174
|
+
"slug": "components/affix",
|
|
175
|
+
"import": "import { Affix } from '@allxsmith/bestax-bulma';",
|
|
176
|
+
"compound": false,
|
|
177
|
+
"propCount": 4,
|
|
178
|
+
"exampleCount": 8
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
"name": "AppFrame",
|
|
182
|
+
"kind": "component",
|
|
183
|
+
"category": "layout",
|
|
184
|
+
"purpose": "The `AppFrame` component lays out an app's pages: a header across the top, a navigation column down the side, the page, and an aside and a footer, with the nav…",
|
|
185
|
+
"slug": "layout/appframe",
|
|
186
|
+
"import": "import { AppFrame, useAppFrame } from '@allxsmith/bestax-bulma';",
|
|
187
|
+
"compound": true,
|
|
188
|
+
"propCount": 35,
|
|
189
|
+
"exampleCount": 8
|
|
190
|
+
},
|
|
167
191
|
{
|
|
168
192
|
"name": "Autocomplete",
|
|
169
193
|
"kind": "component",
|
|
@@ -1530,6 +1554,22 @@
|
|
|
1530
1554
|
}
|
|
1531
1555
|
],
|
|
1532
1556
|
"cssVarIndex": {
|
|
1557
|
+
"--bulma-affix-offset-horizontal": ["Affix"],
|
|
1558
|
+
"--bulma-affix-offset-vertical": ["Affix"],
|
|
1559
|
+
"--bulma-affix-z-index": ["Affix"],
|
|
1560
|
+
"--bulma-app-frame-aside-width": ["AppFrame"],
|
|
1561
|
+
"--bulma-app-frame-backdrop-background": ["AppFrame"],
|
|
1562
|
+
"--bulma-app-frame-border-color": ["AppFrame"],
|
|
1563
|
+
"--bulma-app-frame-border-width": ["AppFrame"],
|
|
1564
|
+
"--bulma-app-frame-drawer-shadow": ["AppFrame"],
|
|
1565
|
+
"--bulma-app-frame-header-background": ["AppFrame"],
|
|
1566
|
+
"--bulma-app-frame-header-height": ["AppFrame"],
|
|
1567
|
+
"--bulma-app-frame-nav-background": ["AppFrame"],
|
|
1568
|
+
"--bulma-app-frame-nav-padding": ["AppFrame"],
|
|
1569
|
+
"--bulma-app-frame-nav-width": ["AppFrame"],
|
|
1570
|
+
"--bulma-app-frame-skip-link-background": ["AppFrame"],
|
|
1571
|
+
"--bulma-app-frame-skip-link-color": ["AppFrame"],
|
|
1572
|
+
"--bulma-app-frame-transition-duration": ["AppFrame"],
|
|
1533
1573
|
"--bulma-autocomplete-border-color": ["Autocomplete"],
|
|
1534
1574
|
"--bulma-autocomplete-border-hover-color": ["Autocomplete"],
|
|
1535
1575
|
"--bulma-autocomplete-dropdown-background": ["Autocomplete"],
|
|
@@ -3080,6 +3120,36 @@
|
|
|
3080
3120
|
"--bulma-tree-view-toggle-size": ["TreeView"]
|
|
3081
3121
|
},
|
|
3082
3122
|
"documentedWith": {
|
|
3123
|
+
"AppFrameAside": {
|
|
3124
|
+
"component": "AppFrame",
|
|
3125
|
+
"path": "AppFrame.Aside",
|
|
3126
|
+
"purpose": "Content beside the page in an AppFrame, which moves under it below the breakpoint."
|
|
3127
|
+
},
|
|
3128
|
+
"AppFrameBurger": {
|
|
3129
|
+
"component": "AppFrame",
|
|
3130
|
+
"path": "AppFrame.Burger",
|
|
3131
|
+
"purpose": "The button that opens the drawer, or collapses the column from the breakpoint up: Navbar.Burger, wired to the frame."
|
|
3132
|
+
},
|
|
3133
|
+
"AppFrameFooter": {
|
|
3134
|
+
"component": "AppFrame",
|
|
3135
|
+
"path": "AppFrame.Footer",
|
|
3136
|
+
"purpose": "The bottom of an AppFrame, under the page."
|
|
3137
|
+
},
|
|
3138
|
+
"AppFrameHeader": {
|
|
3139
|
+
"component": "AppFrame",
|
|
3140
|
+
"path": "AppFrame.Header",
|
|
3141
|
+
"purpose": "The top bar of an AppFrame, which sticks while the page scrolls."
|
|
3142
|
+
},
|
|
3143
|
+
"AppFrameMain": {
|
|
3144
|
+
"component": "AppFrame",
|
|
3145
|
+
"path": "AppFrame.Main",
|
|
3146
|
+
"purpose": "The page's main content in an AppFrame, which the skip link moves focus to."
|
|
3147
|
+
},
|
|
3148
|
+
"AppFrameNav": {
|
|
3149
|
+
"component": "AppFrame",
|
|
3150
|
+
"path": "AppFrame.Nav",
|
|
3151
|
+
"purpose": "The navigation of an AppFrame: a column beside the page from the breakpoint up, and a drawer below it."
|
|
3152
|
+
},
|
|
3083
3153
|
"CarouselItem": {
|
|
3084
3154
|
"component": "Carousel",
|
|
3085
3155
|
"path": "CarouselItem",
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "Affix",
|
|
3
|
+
"kind": "component",
|
|
4
|
+
"category": "components",
|
|
5
|
+
"slug": "components/affix",
|
|
6
|
+
"docsUrl": "https://bestax.io/docs/api/components/affix",
|
|
7
|
+
"examples": [
|
|
8
|
+
{
|
|
9
|
+
"title": "Basic Usage",
|
|
10
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <>\n <Button onClick={() => setShown(!shown)}>\n {shown ? 'Hide the Help button' : 'Show the Help button'}\n </Button>\n {shown && (\n <Affix position=\"bottom-left\">\n <Button color=\"primary\">Help</Button>\n </Affix>\n )}\n </>\n );\n}"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
"title": "Corners",
|
|
14
|
+
"code": "import type { AffixPosition } from '@allxsmith/bestax-bulma';\n\nfunction example() {\n const [position, setPosition] = useState<AffixPosition | null>(null);\n const corners: AffixPosition[] = [\n 'top-left',\n 'top-right',\n 'bottom-left',\n 'bottom-right',\n ];\n return (\n <>\n <Buttons>\n {corners.map(corner => (\n <Button key={corner} onClick={() => setPosition(corner)}>\n {corner}\n </Button>\n ))}\n <Button disabled={!position} onClick={() => setPosition(null)}>\n Hide\n </Button>\n </Buttons>\n {position && (\n <Affix\n position={position}\n mt={position.startsWith('top') ? '6' : undefined}\n mb={position === 'bottom-right' ? '6' : undefined}\n >\n <Button color=\"primary\">Feedback</Button>\n </Affix>\n )}\n </>\n );\n}"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"title": "Nudging One Affix",
|
|
18
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <>\n <Button onClick={() => setShown(!shown)}>\n {shown ? 'Hide the chat button' : 'Show the chat button'}\n </Button>\n {shown && (\n <Affix position=\"bottom-left\" mb=\"6\">\n <IconButton\n icon=\"comments\"\n color=\"link\"\n isRounded\n aria-label=\"Open chat\"\n />\n </Affix>\n )}\n </>\n );\n}"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"title": "Offsets and the Safe Area",
|
|
22
|
+
"code": "<Affix className=\"above-the-tab-bar\">\n <Button color=\"primary\">Help</Button>\n</Affix>"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"title": "Out of a Transformed Ancestor",
|
|
26
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <>\n <Button onClick={() => setShown(!shown)}>\n {shown ? 'Hide the portaled button' : 'Show the portaled button'}\n </Button>\n {shown && (\n <Affix portal position=\"bottom-left\">\n <Button color=\"primary\">Feedback</Button>\n </Affix>\n )}\n </>\n );\n}"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"title": "Several Things in One Corner",
|
|
30
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <>\n <Button onClick={() => setShown(!shown)}>\n {shown ? 'Hide the buttons' : 'Show the buttons'}\n </Button>\n {shown && (\n <Affix\n position=\"bottom-left\"\n display=\"flex\"\n flexDirection=\"column\"\n gap=\"2\"\n >\n <IconButton icon=\"comments\" color=\"link\" aria-label=\"Open chat\" />\n <IconButton icon=\"question\" color=\"primary\" aria-label=\"Help\" />\n </Affix>\n )}\n </>\n );\n}"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"title": "A Consent Notice",
|
|
34
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <>\n <Button onClick={() => setShown(true)}>Show the notice</Button>\n {shown && (\n <Affix position=\"bottom-left\">\n <Box role=\"region\" aria-label=\"Cookie consent\" mb=\"0\">\n <ScrollArea\n maxHeight=\"calc(100dvh - 2 * var(--bulma-affix-offset-vertical) - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 7rem)\"\n aria-label=\"What we store\"\n mb=\"3\"\n >\n <Paragraph>\n We use one cookie to remember your theme. Nothing else is\n stored, and nothing is shared.\n </Paragraph>\n </ScrollArea>\n <Buttons>\n <Button color=\"primary\" onClick={() => setShown(false)}>\n Accept\n </Button>\n <Button onClick={() => setShown(false)}>Decline</Button>\n </Buttons>\n </Box>\n </Affix>\n )}\n </>\n );\n}"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"title": "Right-to-Left",
|
|
38
|
+
"code": "function example() {\n const [shown, setShown] = useState(false);\n return (\n <LocaleProvider locale=\"ar\" dir=\"rtl\">\n <Button onClick={() => setShown(!shown)}>\n {shown ? 'إخفاء' : 'إظهار'}\n </Button>\n {shown && (\n <Affix position=\"bottom-left\">\n <Button color=\"primary\">ملاحظات</Button>\n </Affix>\n )}\n </LocaleProvider>\n );\n}"
|
|
39
|
+
}
|
|
40
|
+
],
|
|
41
|
+
"accessibility": "- **No role:** it's a positioning wrapper, and what's inside keeps its own role. Content that needs\n a landmark, such as a consent notice, brings its own `role=\"region\"` and name, as in\n [A Consent Notice](https://bestax.io/docs/api/components/affix#a-consent-notice).\n- **Reading and Tab order are DOM order:** the corner it shows in says nothing about when a screen\n reader or the Tab key reaches it. In place, that's where you write it, so put it where it belongs\n in the reading order, usually after the page's main content. With `portal` it's appended to its\n container when it mounts, so it comes after what's already there.\n- **Focus not obscured:** a fixed box can cover a focused link near its corner, which fails\n [WCAG 2.4.11](https://www.w3.org/WAI/WCAG22/Understanding/focus-not-obscured-minimum) when it\n hides it entirely. On a page with a bottom-corner Affix, give `html` a `scroll-padding-bottom` at\n least its height plus its offset\n ([technique C43](https://www.w3.org/WAI/WCAG22/Techniques/css/C43)), so a link that Tab scrolls\n into view stops above it, and leave as much room at the end of the page, so the last link can\n scroll clear too:\n\n ```css\n html {\n scroll-padding-bottom: 5rem;\n }\n\n main {\n padding-bottom: 5rem;\n }\n ```\n\n A top-corner Affix takes `scroll-padding-top` the same way. Not every browser scrolls to a\n focused link that's already on screen, so the padding lowers the odds rather than ruling it out,\n and a small Affix leaves less of the page under it.\n\n- **Reflow:** it's never wider than the viewport less its offsets, at 320px too, so its text wraps\n rather than running off the side. It doesn't scroll, so content that can be taller than the\n screen at high zoom has to scroll itself, as in [A Consent Notice](https://bestax.io/docs/api/components/affix#a-consent-notice), with the\n controls that matter outside the scrolling part. A fixed box takes a bigger share of the screen\n at high zoom, so keep what's in it small.\n- **Forced colors:** it draws nothing of its own, so what's inside keeps its own forced colors.\n- **Motion:** it has no motion of its own. What's inside keeps its own transitions.\n- **Right-to-left:** the corner stays where `position` puts it. See\n [Right-to-Left](https://bestax.io/docs/api/components/affix#right-to-left).",
|
|
42
|
+
"related": [
|
|
43
|
+
"Badge",
|
|
44
|
+
"Box",
|
|
45
|
+
"Button",
|
|
46
|
+
"Modal",
|
|
47
|
+
"Portal",
|
|
48
|
+
"ScrollArea",
|
|
49
|
+
"Toast",
|
|
50
|
+
"useBulmaClasses"
|
|
51
|
+
],
|
|
52
|
+
"storybook": "https://bestax.io/storybook/?path=/story/components-affix--default",
|
|
53
|
+
"summary": "The `Affix` component keeps its content fixed to a corner of the viewport while the page scrolls under it. It's a `<div>` with no role, so what's inside keeps its own. It sits `--bulma-affix-offset-vertical` and `--bulma-affix-offset-horizontal` from its corner's edges, plus the device's safe-area inset, and stacks at `--bulma-affix-z-index`, over the page's content and under its navbar, static or fixed, its menus, popovers, the Sidebar, the modals, Tooltip and Toast. It's as wide as its content and never wider than the viewport less its offsets. It doesn't scroll, so nothing inside it is clipped, and content that can be taller than the screen scrolls itself. Its place in the reading and Tab order is its place in the DOM, whatever corner it shows in.",
|
|
54
|
+
"import": "import { Affix } from '@allxsmith/bestax-bulma';",
|
|
55
|
+
"sourceFile": "bulma-ui/src/components/Affix.tsx",
|
|
56
|
+
"rootClass": "affix",
|
|
57
|
+
"parts": [
|
|
58
|
+
{
|
|
59
|
+
"path": "Affix",
|
|
60
|
+
"summary": "The `Affix` component keeps its content fixed to a corner of the viewport while the page scrolls under it. It's a `<div>` with no role, so what's inside keeps its own. It sits `--bulma-affix-offset-vertical` and `--bulma-affix-offset-horizontal` from its corner's edges, plus the device's safe-area inset, and stacks at `--bulma-affix-z-index`, over the page's content and under its navbar, static or fixed, its menus, popovers, the Sidebar, the modals, Tooltip and Toast. It's as wide as its content and never wider than the viewport less its offsets. It doesn't scroll, so nothing inside it is clipped, and content that can be taller than the screen scrolls itself. Its place in the reading and Tab order is its place in the DOM, whatever corner it shows in.",
|
|
61
|
+
"component": null,
|
|
62
|
+
"props": [
|
|
63
|
+
{
|
|
64
|
+
"name": "className",
|
|
65
|
+
"type": "string",
|
|
66
|
+
"default": null,
|
|
67
|
+
"description": "Additional CSS classes to apply.",
|
|
68
|
+
"required": false,
|
|
69
|
+
"inherited": false,
|
|
70
|
+
"deprecated": false
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"name": "children",
|
|
74
|
+
"type": "React.ReactNode",
|
|
75
|
+
"default": null,
|
|
76
|
+
"description": "What stays in the corner.",
|
|
77
|
+
"required": false,
|
|
78
|
+
"inherited": false,
|
|
79
|
+
"deprecated": false
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"name": "position",
|
|
83
|
+
"type": "'top-right' | 'top-left' | 'bottom-right' | 'bottom-left'",
|
|
84
|
+
"default": "'bottom-right'",
|
|
85
|
+
"description": "The corner of the viewport it's fixed to. Physical, as Badge's and Toast's are: `'bottom-right'` stays on the right in right-to-left text. Its distance from the edges is `--bulma-affix-offset-vertical` and `--bulma-affix-offset-horizontal` plus the device's safe-area inset; a margin from the spacing helpers (`mb`, `mr`, …) adds to it. A margin on one side also takes that much of the width its content can have, which the offset variables don't, so move it far with those.",
|
|
86
|
+
"required": false,
|
|
87
|
+
"inherited": false,
|
|
88
|
+
"deprecated": false
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"name": "portal",
|
|
92
|
+
"type": "boolean | string | HTMLElement",
|
|
93
|
+
"default": "false",
|
|
94
|
+
"description": "Renders it into another container, for a page where an ancestor's `transform`, `filter` or `contain` would capture `position: fixed`. `true` portals to the `portalContainer` a `ConfigProvider` sets, `document.body` by default; a string is used as a `document.querySelector` selector; an element is used directly. Renders in place on the server and while hydrating, moving into the portal once the client takes over, so hydration matches. Portaled, it's appended to that container when it mounts, so it comes after what's already there in the reading and Tab order.",
|
|
95
|
+
"required": false,
|
|
96
|
+
"inherited": false,
|
|
97
|
+
"deprecated": false
|
|
98
|
+
}
|
|
99
|
+
],
|
|
100
|
+
"extraProps": [
|
|
101
|
+
{
|
|
102
|
+
"name": "ref",
|
|
103
|
+
"type": "React.Ref<HTMLDivElement>",
|
|
104
|
+
"default": null,
|
|
105
|
+
"description": "Ref forwarded to the `<div>`, wherever it renders.",
|
|
106
|
+
"required": false,
|
|
107
|
+
"inherited": false,
|
|
108
|
+
"deprecated": false
|
|
109
|
+
}
|
|
110
|
+
],
|
|
111
|
+
"catchAll": "All standard <div> attributes and Bulma helper props",
|
|
112
|
+
"types": []
|
|
113
|
+
}
|
|
114
|
+
],
|
|
115
|
+
"cssVars": [
|
|
116
|
+
{
|
|
117
|
+
"css": "--bulma-affix-offset-vertical",
|
|
118
|
+
"sass": "$affix-offset-vertical",
|
|
119
|
+
"default": "$block-spacing",
|
|
120
|
+
"scope": "root"
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"css": "--bulma-affix-offset-horizontal",
|
|
124
|
+
"sass": "$affix-offset-horizontal",
|
|
125
|
+
"default": "$block-spacing",
|
|
126
|
+
"scope": "root"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"css": "--bulma-affix-z-index",
|
|
130
|
+
"sass": "$affix-z-index",
|
|
131
|
+
"default": "$extras-z-index-dropdown - 1",
|
|
132
|
+
"scope": "root"
|
|
133
|
+
}
|
|
134
|
+
]
|
|
135
|
+
}
|