@sakaniui/mcp 0.8.13 → 0.10.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 +4 -2
- package/bin/sakaniui-mcp.mjs +60 -7
- package/data/AGENTS.md +25 -4
- package/data/CHANGELOG.md +35 -0
- package/data/dist/emoji-index.json +1 -0
- package/data/dist/icon-index.json +1 -1
- package/data/dist/manifest.json +145 -7
- package/data/package.json +1 -1
- package/package.json +1 -1
package/data/dist/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 6,
|
|
3
3
|
"name": "@sakaniui/react",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.10.0",
|
|
5
5
|
"description": "Machine-readable contract of the SakaniUI React library, generated from its TypeScript source.",
|
|
6
6
|
"docs": "https://www.sakaniui.com",
|
|
7
7
|
"guide": "https://www.sakaniui.com/llms-full.txt",
|
|
@@ -20,14 +20,15 @@
|
|
|
20
20
|
"entryPoints": {
|
|
21
21
|
"@sakaniui/react": "Components, hooks and helpers.",
|
|
22
22
|
"@sakaniui/react/blocks": "Full sections assembled from components (composition examples).",
|
|
23
|
-
"@sakaniui/react/icons": "Tabler icons: IconName and IconNameFilled, one module each (5184 outline, 1054 filled)."
|
|
23
|
+
"@sakaniui/react/icons": "Tabler icons: IconName and IconNameFilled, one module each (5184 outline, 1054 filled).",
|
|
24
|
+
"@sakaniui/react/emoji": "Fluent Emoji (full colour): EmojiName, one module each (1594 emoji, 311 with skin tones)."
|
|
24
25
|
},
|
|
25
26
|
"conventions": {
|
|
26
|
-
"version": "This manifest describes @sakaniui/react@0.
|
|
27
|
+
"version": "This manifest describes @sakaniui/react@0.10.0. Each component has `since`, the first release that contained it; a prop added later has its own `since`, and a value added later is listed in the prop's `valuesSince`. If the project has an older version installed, anything newer than that does not exist there.",
|
|
27
28
|
"acceptsNativeProps": "Components forward native HTML attributes (className, style, aria-*, event handlers) to their root element unless a prop says otherwise; only the props that are specific to SakaniUI are listed here.",
|
|
28
29
|
"accessibleName": "When `contract.requiresAccessibleName` is true, a required prop (aria-label, aria-labelledby or an alt text) is the only thing that names the control or image. Do not omit it.",
|
|
29
30
|
"tokens": "Use only the token names listed under `tokens`. Colour tokens follow the theme (the `.dark` class flips them); do not hard-code colours.",
|
|
30
|
-
"icons": "Icon props take the component itself (IconSettings), not an element (<IconSettings />). Only names in icon-index.json exist; search them (MCP: search_icons) instead of guessing.",
|
|
31
|
+
"icons": "Icon props take the component itself (IconSettings), not an element (<IconSettings />). Only names in icon-index.json exist; search them (MCP: search_icons) instead of guessing. Emoji are separate (`@sakaniui/react/emoji`, emoji-index.json, MCP: search_emoji) and are rendered as elements, not passed to icon props.",
|
|
31
32
|
"examples": "Each component has `example`: its imports and the element with every required prop filled in, type-checked against this build. Start from it.",
|
|
32
33
|
"shapes": "A prop with a `shape` takes an object (collection \"object\") or an array of objects (collection \"array\") with exactly those fields; `required` fields must be present. In a generic shape (`typeParameters: [\"T\"]`) T is the type of your own data: `key: keyof T & string` means the key must be a field of your row type. `recipes` hold patterns the types alone do not teach.",
|
|
33
34
|
"literals": "Prop `values` keep their real type: a number is a number (columns: 2), a string is a string (\"md\")."
|
|
@@ -458,9 +459,9 @@
|
|
|
458
459
|
}
|
|
459
460
|
},
|
|
460
461
|
"counts": {
|
|
461
|
-
"components":
|
|
462
|
+
"components": 127,
|
|
462
463
|
"blocks": 42,
|
|
463
|
-
"utilities":
|
|
464
|
+
"utilities": 7
|
|
464
465
|
},
|
|
465
466
|
"components": [
|
|
466
467
|
{
|
|
@@ -7613,12 +7614,143 @@
|
|
|
7613
7614
|
"example": "import { Toast } from '@sakaniui/react';\n\n<Toast />",
|
|
7614
7615
|
"aliases": [
|
|
7615
7616
|
"snackbar",
|
|
7616
|
-
"toaster",
|
|
7617
7617
|
"toast notification",
|
|
7618
7618
|
"flash message",
|
|
7619
7619
|
"transient notification"
|
|
7620
7620
|
]
|
|
7621
7621
|
},
|
|
7622
|
+
{
|
|
7623
|
+
"name": "Toaster",
|
|
7624
|
+
"kind": "component",
|
|
7625
|
+
"category": "Composite",
|
|
7626
|
+
"import": "@sakaniui/react",
|
|
7627
|
+
"summary": "Renders the toasts that toast() creates, as a stack on one edge of the screen. Mount one near the root of the app, then call toast() from any handler or module.",
|
|
7628
|
+
"props": [
|
|
7629
|
+
{
|
|
7630
|
+
"name": "position",
|
|
7631
|
+
"type": "\"top-left\" | \"top-center\" | \"top-right\" | \"bottom-left\" | \"bottom-center\" | \"bottom-right\"",
|
|
7632
|
+
"required": false,
|
|
7633
|
+
"values": [
|
|
7634
|
+
"top-left",
|
|
7635
|
+
"top-center",
|
|
7636
|
+
"top-right",
|
|
7637
|
+
"bottom-left",
|
|
7638
|
+
"bottom-center",
|
|
7639
|
+
"bottom-right"
|
|
7640
|
+
],
|
|
7641
|
+
"default": "bottom-right",
|
|
7642
|
+
"description": "Corner or edge the stack sits on. Defaults to \"bottom-right\"."
|
|
7643
|
+
},
|
|
7644
|
+
{
|
|
7645
|
+
"name": "richColors",
|
|
7646
|
+
"type": "boolean",
|
|
7647
|
+
"required": false,
|
|
7648
|
+
"default": false,
|
|
7649
|
+
"description": "Tints success, info, warning and error toasts by type."
|
|
7650
|
+
},
|
|
7651
|
+
{
|
|
7652
|
+
"name": "closeButton",
|
|
7653
|
+
"type": "boolean",
|
|
7654
|
+
"required": false,
|
|
7655
|
+
"default": false,
|
|
7656
|
+
"description": "Shows the round close button on every toast."
|
|
7657
|
+
},
|
|
7658
|
+
{
|
|
7659
|
+
"name": "expand",
|
|
7660
|
+
"type": "boolean",
|
|
7661
|
+
"required": false,
|
|
7662
|
+
"default": false,
|
|
7663
|
+
"description": "Keeps the stack spread out instead of piled up."
|
|
7664
|
+
},
|
|
7665
|
+
{
|
|
7666
|
+
"name": "visibleToasts",
|
|
7667
|
+
"type": "number",
|
|
7668
|
+
"required": false,
|
|
7669
|
+
"default": 3,
|
|
7670
|
+
"description": "How many toasts show at once; older ones fade out. Defaults to 3."
|
|
7671
|
+
},
|
|
7672
|
+
{
|
|
7673
|
+
"name": "duration",
|
|
7674
|
+
"type": "number",
|
|
7675
|
+
"required": false,
|
|
7676
|
+
"default": 4000,
|
|
7677
|
+
"description": "Milliseconds before a toast closes itself. Defaults to 4000."
|
|
7678
|
+
},
|
|
7679
|
+
{
|
|
7680
|
+
"name": "gap",
|
|
7681
|
+
"type": "number",
|
|
7682
|
+
"required": false,
|
|
7683
|
+
"default": 14,
|
|
7684
|
+
"description": "Space between toasts when spread out, in px. Defaults to 14."
|
|
7685
|
+
},
|
|
7686
|
+
{
|
|
7687
|
+
"name": "offset",
|
|
7688
|
+
"type": "string | number",
|
|
7689
|
+
"required": false,
|
|
7690
|
+
"default": 24,
|
|
7691
|
+
"description": "Distance from the viewport edge, in px or any CSS length. Defaults to 24."
|
|
7692
|
+
},
|
|
7693
|
+
{
|
|
7694
|
+
"name": "mobileOffset",
|
|
7695
|
+
"type": "string | number",
|
|
7696
|
+
"required": false,
|
|
7697
|
+
"default": 16,
|
|
7698
|
+
"description": "Distance from the viewport edge on screens 600px wide or less. Defaults to 16."
|
|
7699
|
+
},
|
|
7700
|
+
{
|
|
7701
|
+
"name": "hotkey",
|
|
7702
|
+
"type": "string[]",
|
|
7703
|
+
"required": false,
|
|
7704
|
+
"default": "['altKey', 'KeyT']",
|
|
7705
|
+
"description": "Keys that focus the stack. Defaults to alt+T (`['altKey', 'KeyT']`)."
|
|
7706
|
+
},
|
|
7707
|
+
{
|
|
7708
|
+
"name": "containerAriaLabel",
|
|
7709
|
+
"type": "string",
|
|
7710
|
+
"required": false,
|
|
7711
|
+
"default": "Notifications",
|
|
7712
|
+
"description": "Accessible name of the notifications region. The hotkey is appended. Defaults to \"Notifications\"."
|
|
7713
|
+
},
|
|
7714
|
+
{
|
|
7715
|
+
"name": "className",
|
|
7716
|
+
"type": "string",
|
|
7717
|
+
"required": false
|
|
7718
|
+
},
|
|
7719
|
+
{
|
|
7720
|
+
"name": "style",
|
|
7721
|
+
"type": "CSSProperties",
|
|
7722
|
+
"required": false
|
|
7723
|
+
}
|
|
7724
|
+
],
|
|
7725
|
+
"contract": {
|
|
7726
|
+
"requiredProps": [],
|
|
7727
|
+
"requiresAccessibleName": false
|
|
7728
|
+
},
|
|
7729
|
+
"since": "0.9.0",
|
|
7730
|
+
"example": "import { Toaster } from '@sakaniui/react';\n\n<Toaster />",
|
|
7731
|
+
"recipes": [
|
|
7732
|
+
{
|
|
7733
|
+
"title": "Show a toast from anywhere",
|
|
7734
|
+
"description": "Mount one `<Toaster />` near the root of the app, then call `toast()` (or `toast.success`, `.info`, `.warning`, `.error`, `.loading`) from any handler or module. Do not render `<Toast>` yourself for this: `Toast` is the static, presentational card.",
|
|
7735
|
+
"code": "import { Button, Toaster, toast } from '@sakaniui/react';\n\nexport const App = () => (\n <>\n <Button\n onClick={() =>\n toast.success('Event has been created', {\n description: 'Monday, January 3rd at 6:00pm',\n action: { label: 'Undo', onClick: () => toast('Undone') },\n })\n }\n >\n Create event\n </Button>\n <Toaster position=\"bottom-right\" richColors />\n </>\n);"
|
|
7736
|
+
},
|
|
7737
|
+
{
|
|
7738
|
+
"title": "One toast for an async task",
|
|
7739
|
+
"description": "`toast.promise` shows a loading toast and turns the same toast into success or error when the promise settles. To update any toast by hand, pass the id that `toast()` returned as `id`.",
|
|
7740
|
+
"code": "import { toast } from '@sakaniui/react';\n\ndeclare function saveInvoice(): Promise<{ number: string }>;\n\nexport function onSave() {\n toast.promise(saveInvoice(), {\n loading: 'Saving invoice…',\n success: (invoice) => `Invoice ${invoice.number} saved`,\n error: 'Could not save the invoice',\n });\n\n const id = toast.loading('Uploading…');\n setTimeout(() => toast.success('Uploaded', { id }), 1000);\n}"
|
|
7741
|
+
}
|
|
7742
|
+
],
|
|
7743
|
+
"aliases": [
|
|
7744
|
+
"sonner",
|
|
7745
|
+
"toast stack",
|
|
7746
|
+
"toast provider",
|
|
7747
|
+
"toast container",
|
|
7748
|
+
"toast queue",
|
|
7749
|
+
"notification stack",
|
|
7750
|
+
"stacked toasts",
|
|
7751
|
+
"toast manager"
|
|
7752
|
+
]
|
|
7753
|
+
},
|
|
7622
7754
|
{
|
|
7623
7755
|
"name": "Tooltip",
|
|
7624
7756
|
"kind": "component",
|
|
@@ -11080,6 +11212,12 @@
|
|
|
11080
11212
|
"import": "@sakaniui/react",
|
|
11081
11213
|
"since": "0.4.3"
|
|
11082
11214
|
},
|
|
11215
|
+
{
|
|
11216
|
+
"name": "toast",
|
|
11217
|
+
"kind": "helper",
|
|
11218
|
+
"import": "@sakaniui/react",
|
|
11219
|
+
"since": "0.9.0"
|
|
11220
|
+
},
|
|
11083
11221
|
{
|
|
11084
11222
|
"name": "useHoverHighlight",
|
|
11085
11223
|
"kind": "hook",
|
package/data/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sakaniui/mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "SakaniUI MCP server: lets AI editors look up components, props, tokens and icons, and check code, instead of guessing. Read-only, zero dependencies.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|