@mk-kit/mcp 0.46.0 → 0.48.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/data/api.json +311 -1
- package/data/llms-full.txt +466 -2
- package/data/llms.txt +1 -1
- package/package.json +1 -1
package/data/api.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "@mk-kit/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.48.0",
|
|
4
4
|
"site": "https://mk-kit.dev",
|
|
5
5
|
"entries": [
|
|
6
6
|
{
|
|
@@ -373,6 +373,15 @@
|
|
|
373
373
|
}
|
|
374
374
|
]
|
|
375
375
|
},
|
|
376
|
+
{
|
|
377
|
+
"name": "mkBodyLevelAncestor",
|
|
378
|
+
"description": "The direct child of `document.body` an overlay-root descendant lives under,\ncrossing shadow boundaries on the way up — `null` when the node is not under\n`body` at all. The overlay service uses it to keep the overlay's own host\nout of the elements it makes `inert` behind a modal.",
|
|
379
|
+
"file": "projects/mk-kit/core/overlay/overlay-root.ts",
|
|
380
|
+
"kind": "function",
|
|
381
|
+
"signatures": [
|
|
382
|
+
"(node: Node, body: HTMLElement): Element | null"
|
|
383
|
+
]
|
|
384
|
+
},
|
|
376
385
|
{
|
|
377
386
|
"name": "mkComputeAnchoredPosition",
|
|
378
387
|
"description": "Pure viewport-positioning maths shared by every anchored overlay\n(`MkAnchoredPanel` and the tooltip). Given the anchor rect, the panel\nsize and the viewport size, returns the top/left for a `position: fixed`\npanel — flipping to the opposite side when it would overflow and clamping\nback inside the viewport.",
|
|
@@ -620,6 +629,13 @@
|
|
|
620
629
|
"kind": "token",
|
|
621
630
|
"type": "InjectionToken<unknown>"
|
|
622
631
|
},
|
|
632
|
+
{
|
|
633
|
+
"name": "MK_OVERLAY_ROOT",
|
|
634
|
+
"description": "Where mk-kit mounts everything that leaves the component tree: overlay\ncontainers (dialogs), anchored panels (selects, menus, tooltips), toast /\nsnackbar containers and the tour surfaces. Defaults to `document.body`.\n\nOverride it to confine those surfaces to another element — `@mk-kit/ui/embed`\npoints it at a themed shadow-DOM host so overlays opened by embedded custom\nelements stay isolated from the host page's stylesheet:\n\n```ts\n{ provide: MK_OVERLAY_ROOT, useValue: () => myOverlayHost }\n```",
|
|
635
|
+
"file": "projects/mk-kit/core/overlay/overlay-root.ts",
|
|
636
|
+
"kind": "token",
|
|
637
|
+
"type": "InjectionToken<MkOverlayRootFn>"
|
|
638
|
+
},
|
|
623
639
|
{
|
|
624
640
|
"name": "MK_DEFAULT_BREAKPOINTS",
|
|
625
641
|
"description": "The default scale (same numbers as Tailwind, so mental models transfer).",
|
|
@@ -3140,6 +3156,13 @@
|
|
|
3140
3156
|
"kind": "type",
|
|
3141
3157
|
"definition": "Partial< Omit<MkI18nStrings, 'dateNames' | 'blockEditor' | 'validation'> > & { dateNames?: Partial<MkDateNames>; blockEditor?: Partial<MkBlockEditorStrings>; validation?: Partial<MkValidationStrings>; }"
|
|
3142
3158
|
},
|
|
3159
|
+
{
|
|
3160
|
+
"name": "MkOverlayRootFn",
|
|
3161
|
+
"description": "Resolves the element overlay surfaces are appended to. A function (not an\nelement) because the root may be created lazily, after DI is set up.",
|
|
3162
|
+
"file": "projects/mk-kit/core/overlay/overlay-root.ts",
|
|
3163
|
+
"kind": "type",
|
|
3164
|
+
"definition": "() => HTMLElement"
|
|
3165
|
+
},
|
|
3143
3166
|
{
|
|
3144
3167
|
"name": "MkPlacement",
|
|
3145
3168
|
"description": "Common placement values for overlays (menus, tooltips, popovers).",
|
|
@@ -22459,6 +22482,241 @@
|
|
|
22459
22482
|
}
|
|
22460
22483
|
]
|
|
22461
22484
|
},
|
|
22485
|
+
{
|
|
22486
|
+
"name": "embed",
|
|
22487
|
+
"import": "@mk-kit/ui/embed",
|
|
22488
|
+
"exports": [
|
|
22489
|
+
{
|
|
22490
|
+
"name": "MkEmbedApp",
|
|
22491
|
+
"description": "One shared embed application. Create it with `mkEmbed`.",
|
|
22492
|
+
"file": "projects/mk-kit/embed/embed.ts",
|
|
22493
|
+
"kind": "class",
|
|
22494
|
+
"methods": [
|
|
22495
|
+
{
|
|
22496
|
+
"name": "element",
|
|
22497
|
+
"signature": "(tag: string, component: Type<unknown>): this",
|
|
22498
|
+
"description": "Defines `tag` as a custom element rendering `component`. Chainable; a\nno-op when the tag is already defined (hot reload, duplicate script) or\noutside a browser."
|
|
22499
|
+
},
|
|
22500
|
+
{
|
|
22501
|
+
"name": "ready",
|
|
22502
|
+
"signature": "(): Promise<void>",
|
|
22503
|
+
"description": "Resolves when the shared application is running (created on demand)."
|
|
22504
|
+
},
|
|
22505
|
+
{
|
|
22506
|
+
"name": "whenStable",
|
|
22507
|
+
"signature": "(): Promise<void>",
|
|
22508
|
+
"description": "Resolves when the application has no pending change detection."
|
|
22509
|
+
},
|
|
22510
|
+
{
|
|
22511
|
+
"name": "destroy",
|
|
22512
|
+
"signature": "(): void",
|
|
22513
|
+
"description": "Destroys the shared application, every mounted component and the overlay\nhost. Defined tags remain registered (the platform cannot undefine them)\nbut render nothing afterwards."
|
|
22514
|
+
}
|
|
22515
|
+
],
|
|
22516
|
+
"properties": []
|
|
22517
|
+
},
|
|
22518
|
+
{
|
|
22519
|
+
"name": "mkEmbed",
|
|
22520
|
+
"description": "Creates an embed application: a factory for custom elements that render\nmk-kit-based Angular components behind shadow DOM.\n\n- **Lazy**: `element()` only defines the tag; the Angular application is\n created on the first element actually connected to a document.\n- **Shared**: every element of one `mkEmbed()` call runs in one zoneless\n `ApplicationRef` with one provider set.\n- **Isolated but themable**: the host page's CSS cannot reach the widget\n internals, while `--mk-*` custom properties still inherit through the\n shadow boundary — set them on the element (or any ancestor) to theme it.\n- **Styled**: Angular routes each component's own styles into the shadow\n root it renders in; the `styles` option supplies the token/theme layer.\n\n```ts\nimport { mkEmbed, mkShadowCss } from '@mk-kit/ui/embed';\nimport themeCss from '@mk-kit/ui/styles.css' with { type: 'text' };\n\nmkEmbed({ styles: mkShadowCss(themeCss) })\n .element('acme-reviews', ReviewsWidget)\n .element('acme-signup', SignupWidget);\n```\n\n```html\n<acme-reviews product-id=\"42\" style=\"--mk-primary: #7c3aed\"></acme-reviews>\n```\n\nInputs are exposed as dash-cased attributes (string values go through the\ninput's `transform`, so `booleanAttribute` / `numberAttribute` inputs coerce\nas usual) and as camel-cased element properties (any value); outputs become\nbubbling, composed `CustomEvent`s named after the output, with the emitted\nvalue as `detail`.",
|
|
22521
|
+
"file": "projects/mk-kit/embed/embed.ts",
|
|
22522
|
+
"kind": "function",
|
|
22523
|
+
"signatures": [
|
|
22524
|
+
"(init?: MkEmbedInit): MkEmbedApp"
|
|
22525
|
+
]
|
|
22526
|
+
},
|
|
22527
|
+
{
|
|
22528
|
+
"name": "mkShadowCss",
|
|
22529
|
+
"description": "Rewrites a document-level stylesheet for adoption into a shadow root:\n`:root` never matches inside one, so token blocks like mk-kit's\n`:root { --mk-primary: … }` are retargeted to `:host`. Theme opt-ins keep\nworking — `:root:not([data-mk-theme='light'])` becomes\n`:host:not([data-mk-theme='light'])`, so `<my-widget data-mk-theme=\"dark\">`\nswitches one embedded element to the dark palette.\n\n```ts\nimport themeCss from '@mk-kit/ui/styles.css' with { type: 'text' };\nmkEmbed({ styles: mkShadowCss(themeCss) });\n```",
|
|
22530
|
+
"file": "projects/mk-kit/embed/shadow-css.ts",
|
|
22531
|
+
"kind": "function",
|
|
22532
|
+
"signatures": [
|
|
22533
|
+
"(css: string): string"
|
|
22534
|
+
]
|
|
22535
|
+
},
|
|
22536
|
+
{
|
|
22537
|
+
"name": "MkEmbedInit",
|
|
22538
|
+
"description": "Options for `mkEmbed`.",
|
|
22539
|
+
"file": "projects/mk-kit/embed/embed.ts",
|
|
22540
|
+
"kind": "interface",
|
|
22541
|
+
"members": [
|
|
22542
|
+
{
|
|
22543
|
+
"name": "styles",
|
|
22544
|
+
"type": "string | readonly string[] | undefined",
|
|
22545
|
+
"description": "CSS text adopted into every element's shadow root (and the overlay host).\nPass the mk-kit theme through `mkShadowCss` so its `:root` token\nblocks target `:host`; append your own widget CSS after it. Shared as\nconstructable stylesheets when the browser supports them (one parse for\nany number of instances), `<style>` elements otherwise.",
|
|
22546
|
+
"optional": true
|
|
22547
|
+
},
|
|
22548
|
+
{
|
|
22549
|
+
"name": "providers",
|
|
22550
|
+
"type": "(Provider | EnvironmentProviders)[] | undefined",
|
|
22551
|
+
"description": "Extra providers for the shared application — `provideMkI18n(…)`,\n`provideMkExtendedIcons()`, `provideHttpClient()`, your services.",
|
|
22552
|
+
"optional": true
|
|
22553
|
+
},
|
|
22554
|
+
{
|
|
22555
|
+
"name": "overlays",
|
|
22556
|
+
"type": "boolean | undefined",
|
|
22557
|
+
"description": "Mount mk-kit overlays (dialogs, anchored panels, toasts, tours) inside a\npage-level shadow host that carries the same `styles`, instead of bare\n`document.body`. Default `true`; set `false` to keep the application\ndefault (overlays styled by the page's own stylesheets).",
|
|
22558
|
+
"optional": true
|
|
22559
|
+
}
|
|
22560
|
+
]
|
|
22561
|
+
}
|
|
22562
|
+
]
|
|
22563
|
+
},
|
|
22564
|
+
{
|
|
22565
|
+
"name": "locales/de",
|
|
22566
|
+
"import": "@mk-kit/ui/locales/de",
|
|
22567
|
+
"exports": [
|
|
22568
|
+
{
|
|
22569
|
+
"name": "mkPluralDe",
|
|
22570
|
+
"description": "Picks the German plural form for a count — CLDR's `de` rules for integers:\n`one` for 1, `other` for everything else.\n\n```ts\nmkPluralDe(1, 'Ergebnis', 'Ergebnisse'); // 'Ergebnis'\nmkPluralDe(3, 'Ergebnis', 'Ergebnisse'); // 'Ergebnisse'\n```",
|
|
22571
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22572
|
+
"kind": "function",
|
|
22573
|
+
"signatures": [
|
|
22574
|
+
"(count: number, one: string, other: string): string"
|
|
22575
|
+
]
|
|
22576
|
+
},
|
|
22577
|
+
{
|
|
22578
|
+
"name": "provideMkI18nDe",
|
|
22579
|
+
"description": "Provides the German strings — `MK_DE_I18N` with any `overrides`\nmerged on top (deep for `dateNames`, `blockEditor` and `validation`, like\n`provideMkI18n`).\n\n```ts\nbootstrapApplication(App, {\n providers: [provideMkI18nDe({ noData: 'Nichts zu sehen' })],\n});\n```",
|
|
22580
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22581
|
+
"kind": "function",
|
|
22582
|
+
"signatures": [
|
|
22583
|
+
"(overrides?: MkI18nOverrides): Provider"
|
|
22584
|
+
]
|
|
22585
|
+
},
|
|
22586
|
+
{
|
|
22587
|
+
"name": "MK_DE_BLOCK_EDITOR",
|
|
22588
|
+
"description": "German strings of the block editor's chrome.",
|
|
22589
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22590
|
+
"kind": "const",
|
|
22591
|
+
"type": "MkBlockEditorStrings"
|
|
22592
|
+
},
|
|
22593
|
+
{
|
|
22594
|
+
"name": "MK_DE_DATE_NAMES",
|
|
22595
|
+
"description": "German month and weekday names (Sunday-first, as in `Intl`).",
|
|
22596
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22597
|
+
"kind": "const",
|
|
22598
|
+
"type": "MkDateNames"
|
|
22599
|
+
},
|
|
22600
|
+
{
|
|
22601
|
+
"name": "MK_DE_I18N",
|
|
22602
|
+
"description": "The complete German string map — every key of `MkI18nStrings`,\n`locale: 'de-DE'` and `currency: 'EUR'` for the formatting pipes.\nProvide it whole with `provideMkI18nDe`, or pass it as the base of\n`provideMkI18n(overrides, MK_DE_I18N)`.",
|
|
22603
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22604
|
+
"kind": "const",
|
|
22605
|
+
"type": "MkI18nStrings"
|
|
22606
|
+
},
|
|
22607
|
+
{
|
|
22608
|
+
"name": "MK_DE_VALIDATION",
|
|
22609
|
+
"description": "German validation messages rendered by `mk-form-field`.",
|
|
22610
|
+
"file": "projects/mk-kit/locales/de/de.ts",
|
|
22611
|
+
"kind": "const",
|
|
22612
|
+
"type": "MkValidationStrings"
|
|
22613
|
+
}
|
|
22614
|
+
]
|
|
22615
|
+
},
|
|
22616
|
+
{
|
|
22617
|
+
"name": "locales/es",
|
|
22618
|
+
"import": "@mk-kit/ui/locales/es",
|
|
22619
|
+
"exports": [
|
|
22620
|
+
{
|
|
22621
|
+
"name": "mkPluralEs",
|
|
22622
|
+
"description": "Picks the Spanish plural form for a count — CLDR's `es` rules for integers:\n`one` for 1, `other` for everything else.\n\n```ts\nmkPluralEs(1, 'resultado', 'resultados'); // 'resultado'\nmkPluralEs(3, 'resultado', 'resultados'); // 'resultados'\n```",
|
|
22623
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22624
|
+
"kind": "function",
|
|
22625
|
+
"signatures": [
|
|
22626
|
+
"(count: number, one: string, other: string): string"
|
|
22627
|
+
]
|
|
22628
|
+
},
|
|
22629
|
+
{
|
|
22630
|
+
"name": "provideMkI18nEs",
|
|
22631
|
+
"description": "Provides the Spanish strings — `MK_ES_I18N` with any `overrides`\nmerged on top (deep for `dateNames`, `blockEditor` and `validation`, like\n`provideMkI18n`).\n\n```ts\nbootstrapApplication(App, {\n providers: [provideMkI18nEs({ noData: 'No hay nada aquí' })],\n});\n```",
|
|
22632
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22633
|
+
"kind": "function",
|
|
22634
|
+
"signatures": [
|
|
22635
|
+
"(overrides?: MkI18nOverrides): Provider"
|
|
22636
|
+
]
|
|
22637
|
+
},
|
|
22638
|
+
{
|
|
22639
|
+
"name": "MK_ES_BLOCK_EDITOR",
|
|
22640
|
+
"description": "Spanish strings of the block editor's chrome.",
|
|
22641
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22642
|
+
"kind": "const",
|
|
22643
|
+
"type": "MkBlockEditorStrings"
|
|
22644
|
+
},
|
|
22645
|
+
{
|
|
22646
|
+
"name": "MK_ES_DATE_NAMES",
|
|
22647
|
+
"description": "Spanish month and weekday names (Sunday-first, lowercase as in `Intl`).",
|
|
22648
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22649
|
+
"kind": "const",
|
|
22650
|
+
"type": "MkDateNames"
|
|
22651
|
+
},
|
|
22652
|
+
{
|
|
22653
|
+
"name": "MK_ES_I18N",
|
|
22654
|
+
"description": "The complete Spanish string map — every key of `MkI18nStrings`,\n`locale: 'es-ES'` and `currency: 'EUR'` for the formatting pipes.\nProvide it whole with `provideMkI18nEs`, or pass it as the base of\n`provideMkI18n(overrides, MK_ES_I18N)`.",
|
|
22655
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22656
|
+
"kind": "const",
|
|
22657
|
+
"type": "MkI18nStrings"
|
|
22658
|
+
},
|
|
22659
|
+
{
|
|
22660
|
+
"name": "MK_ES_VALIDATION",
|
|
22661
|
+
"description": "Spanish validation messages rendered by `mk-form-field`.",
|
|
22662
|
+
"file": "projects/mk-kit/locales/es/es.ts",
|
|
22663
|
+
"kind": "const",
|
|
22664
|
+
"type": "MkValidationStrings"
|
|
22665
|
+
}
|
|
22666
|
+
]
|
|
22667
|
+
},
|
|
22668
|
+
{
|
|
22669
|
+
"name": "locales/fr",
|
|
22670
|
+
"import": "@mk-kit/ui/locales/fr",
|
|
22671
|
+
"exports": [
|
|
22672
|
+
{
|
|
22673
|
+
"name": "mkPluralFr",
|
|
22674
|
+
"description": "Picks the French plural form for a count — CLDR's `fr` rules for integers:\n`one` for 0 and 1, `other` for everything else.\n\n```ts\nmkPluralFr(1, 'résultat', 'résultats'); // 'résultat'\nmkPluralFr(0, 'résultat', 'résultats'); // 'résultat'\nmkPluralFr(3, 'résultat', 'résultats'); // 'résultats'\n```",
|
|
22675
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22676
|
+
"kind": "function",
|
|
22677
|
+
"signatures": [
|
|
22678
|
+
"(count: number, one: string, other: string): string"
|
|
22679
|
+
]
|
|
22680
|
+
},
|
|
22681
|
+
{
|
|
22682
|
+
"name": "provideMkI18nFr",
|
|
22683
|
+
"description": "Provides the French strings — `MK_FR_I18N` with any `overrides`\nmerged on top (deep for `dateNames`, `blockEditor` and `validation`, like\n`provideMkI18n`).\n\n```ts\nbootstrapApplication(App, {\n providers: [provideMkI18nFr({ noData: 'Rien à afficher ici' })],\n});\n```",
|
|
22684
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22685
|
+
"kind": "function",
|
|
22686
|
+
"signatures": [
|
|
22687
|
+
"(overrides?: MkI18nOverrides): Provider"
|
|
22688
|
+
]
|
|
22689
|
+
},
|
|
22690
|
+
{
|
|
22691
|
+
"name": "MK_FR_BLOCK_EDITOR",
|
|
22692
|
+
"description": "French strings of the block editor's chrome.",
|
|
22693
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22694
|
+
"kind": "const",
|
|
22695
|
+
"type": "MkBlockEditorStrings"
|
|
22696
|
+
},
|
|
22697
|
+
{
|
|
22698
|
+
"name": "MK_FR_DATE_NAMES",
|
|
22699
|
+
"description": "French month and weekday names (Sunday-first, lowercase as in `Intl`).",
|
|
22700
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22701
|
+
"kind": "const",
|
|
22702
|
+
"type": "MkDateNames"
|
|
22703
|
+
},
|
|
22704
|
+
{
|
|
22705
|
+
"name": "MK_FR_I18N",
|
|
22706
|
+
"description": "The complete French string map — every key of `MkI18nStrings`,\n`locale: 'fr-FR'` and `currency: 'EUR'` for the formatting pipes.\nProvide it whole with `provideMkI18nFr`, or pass it as the base of\n`provideMkI18n(overrides, MK_FR_I18N)`.",
|
|
22707
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22708
|
+
"kind": "const",
|
|
22709
|
+
"type": "MkI18nStrings"
|
|
22710
|
+
},
|
|
22711
|
+
{
|
|
22712
|
+
"name": "MK_FR_VALIDATION",
|
|
22713
|
+
"description": "French validation messages rendered by `mk-form-field`.",
|
|
22714
|
+
"file": "projects/mk-kit/locales/fr/fr.ts",
|
|
22715
|
+
"kind": "const",
|
|
22716
|
+
"type": "MkValidationStrings"
|
|
22717
|
+
}
|
|
22718
|
+
]
|
|
22719
|
+
},
|
|
22462
22720
|
{
|
|
22463
22721
|
"name": "locales/pl",
|
|
22464
22722
|
"import": "@mk-kit/ui/locales/pl",
|
|
@@ -22511,6 +22769,58 @@
|
|
|
22511
22769
|
}
|
|
22512
22770
|
]
|
|
22513
22771
|
},
|
|
22772
|
+
{
|
|
22773
|
+
"name": "locales/uk",
|
|
22774
|
+
"import": "@mk-kit/ui/locales/uk",
|
|
22775
|
+
"exports": [
|
|
22776
|
+
{
|
|
22777
|
+
"name": "mkPluralUk",
|
|
22778
|
+
"description": "Picks the Ukrainian plural form for a count — CLDR's `uk` rules for\nintegers: `one` when the number ends in 1 (but not 11), `few` when it ends\nin 2–4 (but not 12–14), `many` otherwise.\n\n```ts\nmkPluralUk(1, 'результат', 'результати', 'результатів'); // 'результат'\nmkPluralUk(3, 'результат', 'результати', 'результатів'); // 'результати'\nmkPluralUk(11, 'результат', 'результати', 'результатів'); // 'результатів'\n```",
|
|
22779
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22780
|
+
"kind": "function",
|
|
22781
|
+
"signatures": [
|
|
22782
|
+
"(count: number, one: string, few: string, many: string): string"
|
|
22783
|
+
]
|
|
22784
|
+
},
|
|
22785
|
+
{
|
|
22786
|
+
"name": "provideMkI18nUk",
|
|
22787
|
+
"description": "Provides the Ukrainian strings — `MK_UK_I18N` with any `overrides`\nmerged on top (deep for `dateNames`, `blockEditor` and `validation`, like\n`provideMkI18n`).\n\n```ts\nbootstrapApplication(App, {\n providers: [provideMkI18nUk({ noData: 'Тут нічого немає' })],\n});\n```",
|
|
22788
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22789
|
+
"kind": "function",
|
|
22790
|
+
"signatures": [
|
|
22791
|
+
"(overrides?: MkI18nOverrides): Provider"
|
|
22792
|
+
]
|
|
22793
|
+
},
|
|
22794
|
+
{
|
|
22795
|
+
"name": "MK_UK_BLOCK_EDITOR",
|
|
22796
|
+
"description": "Ukrainian strings of the block editor's chrome.",
|
|
22797
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22798
|
+
"kind": "const",
|
|
22799
|
+
"type": "MkBlockEditorStrings"
|
|
22800
|
+
},
|
|
22801
|
+
{
|
|
22802
|
+
"name": "MK_UK_DATE_NAMES",
|
|
22803
|
+
"description": "Ukrainian month and weekday names (Sunday-first, lowercase as in `Intl`).",
|
|
22804
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22805
|
+
"kind": "const",
|
|
22806
|
+
"type": "MkDateNames"
|
|
22807
|
+
},
|
|
22808
|
+
{
|
|
22809
|
+
"name": "MK_UK_I18N",
|
|
22810
|
+
"description": "The complete Ukrainian string map — every key of `MkI18nStrings`,\n`locale: 'uk-UA'` and `currency: 'UAH'` for the formatting pipes.\nProvide it whole with `provideMkI18nUk`, or pass it as the base of\n`provideMkI18n(overrides, MK_UK_I18N)`.",
|
|
22811
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22812
|
+
"kind": "const",
|
|
22813
|
+
"type": "MkI18nStrings"
|
|
22814
|
+
},
|
|
22815
|
+
{
|
|
22816
|
+
"name": "MK_UK_VALIDATION",
|
|
22817
|
+
"description": "Ukrainian validation messages rendered by `mk-form-field`.",
|
|
22818
|
+
"file": "projects/mk-kit/locales/uk/uk.ts",
|
|
22819
|
+
"kind": "const",
|
|
22820
|
+
"type": "MkValidationStrings"
|
|
22821
|
+
}
|
|
22822
|
+
]
|
|
22823
|
+
},
|
|
22514
22824
|
{
|
|
22515
22825
|
"name": "testing",
|
|
22516
22826
|
"import": "@mk-kit/ui/testing",
|
package/data/llms-full.txt
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @mk-kit/ui 0.
|
|
1
|
+
# @mk-kit/ui 0.48.0 — full API reference
|
|
2
2
|
|
|
3
3
|
Generated from the library sources. Browsable version: https://mk-kit.dev/api · JSON: https://mk-kit.dev/api.json · Guides: https://mk-kit.dev/llms.txt
|
|
4
4
|
|
|
@@ -12,7 +12,7 @@ Every component and directive below is standalone — import the class from its
|
|
|
12
12
|
|
|
13
13
|
## @mk-kit/ui/core
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
79 exports. `import { … } from '@mk-kit/ui/core';`
|
|
16
16
|
|
|
17
17
|
### MkAnchoredPanel (directive)
|
|
18
18
|
|
|
@@ -250,6 +250,19 @@ Properties:
|
|
|
250
250
|
| `afterClosed` | `Promise<TResult \| undefined>` | Resolves with the close result when the overlay is dismissed. |
|
|
251
251
|
| `closed$` | `Observable<TResult \| undefined>` | Emits the close result once, then completes. Subscribing after the overlay has already closed replays the result immediately, so a late subscriber never hangs. |
|
|
252
252
|
|
|
253
|
+
### mkBodyLevelAncestor (function)
|
|
254
|
+
|
|
255
|
+
Import: `import { mkBodyLevelAncestor } from '@mk-kit/ui/core';`
|
|
256
|
+
|
|
257
|
+
The direct child of `document.body` an overlay-root descendant lives under,
|
|
258
|
+
crossing shadow boundaries on the way up — `null` when the node is not under
|
|
259
|
+
`body` at all. The overlay service uses it to keep the overlay's own host
|
|
260
|
+
out of the elements it makes `inert` behind a modal.
|
|
261
|
+
|
|
262
|
+
```ts
|
|
263
|
+
function mkBodyLevelAncestor(node: Node, body: HTMLElement): Element | null
|
|
264
|
+
```
|
|
265
|
+
|
|
253
266
|
### mkComputeAnchoredPosition (function)
|
|
254
267
|
|
|
255
268
|
Import: `import { mkComputeAnchoredPosition } from '@mk-kit/ui/core';`
|
|
@@ -618,6 +631,26 @@ Injection token exposing the data passed to an overlay component.
|
|
|
618
631
|
const MK_OVERLAY_DATA: InjectionToken<unknown>;
|
|
619
632
|
```
|
|
620
633
|
|
|
634
|
+
### MK_OVERLAY_ROOT (token)
|
|
635
|
+
|
|
636
|
+
Import: `import { MK_OVERLAY_ROOT } from '@mk-kit/ui/core';`
|
|
637
|
+
|
|
638
|
+
Where mk-kit mounts everything that leaves the component tree: overlay
|
|
639
|
+
containers (dialogs), anchored panels (selects, menus, tooltips), toast /
|
|
640
|
+
snackbar containers and the tour surfaces. Defaults to `document.body`.
|
|
641
|
+
|
|
642
|
+
Override it to confine those surfaces to another element — `@mk-kit/ui/embed`
|
|
643
|
+
points it at a themed shadow-DOM host so overlays opened by embedded custom
|
|
644
|
+
elements stay isolated from the host page's stylesheet:
|
|
645
|
+
|
|
646
|
+
```ts
|
|
647
|
+
{ provide: MK_OVERLAY_ROOT, useValue: () => myOverlayHost }
|
|
648
|
+
```
|
|
649
|
+
|
|
650
|
+
```ts
|
|
651
|
+
const MK_OVERLAY_ROOT: InjectionToken<MkOverlayRootFn>;
|
|
652
|
+
```
|
|
653
|
+
|
|
621
654
|
### MK_DEFAULT_BREAKPOINTS (const)
|
|
622
655
|
|
|
623
656
|
Import: `import { MK_DEFAULT_BREAKPOINTS } from '@mk-kit/ui/core';`
|
|
@@ -1390,6 +1423,17 @@ and `validation` groups may be partial too (they are merged deeply).
|
|
|
1390
1423
|
type MkI18nOverrides = Partial< Omit<MkI18nStrings, 'dateNames' | 'blockEditor' | 'validation'> > & { dateNames?: Partial<MkDateNames>; blockEditor?: Partial<MkBlockEditorStrings>; validation?: Partial<MkValidationStrings>; };
|
|
1391
1424
|
```
|
|
1392
1425
|
|
|
1426
|
+
### MkOverlayRootFn (type)
|
|
1427
|
+
|
|
1428
|
+
Import: `import { MkOverlayRootFn } from '@mk-kit/ui/core';`
|
|
1429
|
+
|
|
1430
|
+
Resolves the element overlay surfaces are appended to. A function (not an
|
|
1431
|
+
element) because the root may be created lazily, after DI is set up.
|
|
1432
|
+
|
|
1433
|
+
```ts
|
|
1434
|
+
type MkOverlayRootFn = () => HTMLElement;
|
|
1435
|
+
```
|
|
1436
|
+
|
|
1393
1437
|
### MkPlacement (type)
|
|
1394
1438
|
|
|
1395
1439
|
Import: `import { MkPlacement } from '@mk-kit/ui/core';`
|
|
@@ -15001,6 +15045,343 @@ Load lifecycle of an `MkImage`.
|
|
|
15001
15045
|
type MkImageState = 'loading' | 'loaded' | 'error';
|
|
15002
15046
|
```
|
|
15003
15047
|
|
|
15048
|
+
## @mk-kit/ui/embed
|
|
15049
|
+
|
|
15050
|
+
4 exports. `import { … } from '@mk-kit/ui/embed';`
|
|
15051
|
+
|
|
15052
|
+
### MkEmbedApp (class)
|
|
15053
|
+
|
|
15054
|
+
Import: `import { MkEmbedApp } from '@mk-kit/ui/embed';`
|
|
15055
|
+
|
|
15056
|
+
One shared embed application. Create it with `mkEmbed`.
|
|
15057
|
+
|
|
15058
|
+
Methods:
|
|
15059
|
+
|
|
15060
|
+
| Signature | Description |
|
|
15061
|
+
| --- | --- |
|
|
15062
|
+
| `element(tag: string, component: Type<unknown>): this` | Defines `tag` as a custom element rendering `component`. Chainable; a no-op when the tag is already defined (hot reload, duplicate script) or outside a browser. |
|
|
15063
|
+
| `ready(): Promise<void>` | Resolves when the shared application is running (created on demand). |
|
|
15064
|
+
| `whenStable(): Promise<void>` | Resolves when the application has no pending change detection. |
|
|
15065
|
+
| `destroy(): void` | Destroys the shared application, every mounted component and the overlay host. Defined tags remain registered (the platform cannot undefine them) but render nothing afterwards. |
|
|
15066
|
+
|
|
15067
|
+
### mkEmbed (function)
|
|
15068
|
+
|
|
15069
|
+
Import: `import { mkEmbed } from '@mk-kit/ui/embed';`
|
|
15070
|
+
|
|
15071
|
+
Creates an embed application: a factory for custom elements that render
|
|
15072
|
+
mk-kit-based Angular components behind shadow DOM.
|
|
15073
|
+
|
|
15074
|
+
- **Lazy**: `element()` only defines the tag; the Angular application is
|
|
15075
|
+
created on the first element actually connected to a document.
|
|
15076
|
+
- **Shared**: every element of one `mkEmbed()` call runs in one zoneless
|
|
15077
|
+
`ApplicationRef` with one provider set.
|
|
15078
|
+
- **Isolated but themable**: the host page's CSS cannot reach the widget
|
|
15079
|
+
internals, while `--mk-*` custom properties still inherit through the
|
|
15080
|
+
shadow boundary — set them on the element (or any ancestor) to theme it.
|
|
15081
|
+
- **Styled**: Angular routes each component's own styles into the shadow
|
|
15082
|
+
root it renders in; the `styles` option supplies the token/theme layer.
|
|
15083
|
+
|
|
15084
|
+
```ts
|
|
15085
|
+
import { mkEmbed, mkShadowCss } from '@mk-kit/ui/embed';
|
|
15086
|
+
import themeCss from '@mk-kit/ui/styles.css' with { type: 'text' };
|
|
15087
|
+
|
|
15088
|
+
mkEmbed({ styles: mkShadowCss(themeCss) })
|
|
15089
|
+
.element('acme-reviews', ReviewsWidget)
|
|
15090
|
+
.element('acme-signup', SignupWidget);
|
|
15091
|
+
```
|
|
15092
|
+
|
|
15093
|
+
```html
|
|
15094
|
+
<acme-reviews product-id="42" style="--mk-primary: #7c3aed"></acme-reviews>
|
|
15095
|
+
```
|
|
15096
|
+
|
|
15097
|
+
Inputs are exposed as dash-cased attributes (string values go through the
|
|
15098
|
+
input's `transform`, so `booleanAttribute` / `numberAttribute` inputs coerce
|
|
15099
|
+
as usual) and as camel-cased element properties (any value); outputs become
|
|
15100
|
+
bubbling, composed `CustomEvent`s named after the output, with the emitted
|
|
15101
|
+
value as `detail`.
|
|
15102
|
+
|
|
15103
|
+
```ts
|
|
15104
|
+
function mkEmbed(init?: MkEmbedInit): MkEmbedApp
|
|
15105
|
+
```
|
|
15106
|
+
|
|
15107
|
+
### mkShadowCss (function)
|
|
15108
|
+
|
|
15109
|
+
Import: `import { mkShadowCss } from '@mk-kit/ui/embed';`
|
|
15110
|
+
|
|
15111
|
+
Rewrites a document-level stylesheet for adoption into a shadow root:
|
|
15112
|
+
`:root` never matches inside one, so token blocks like mk-kit's
|
|
15113
|
+
`:root { --mk-primary: … }` are retargeted to `:host`. Theme opt-ins keep
|
|
15114
|
+
working — `:root:not([data-mk-theme='light'])` becomes
|
|
15115
|
+
`:host:not([data-mk-theme='light'])`, so `<my-widget data-mk-theme="dark">`
|
|
15116
|
+
switches one embedded element to the dark palette.
|
|
15117
|
+
|
|
15118
|
+
```ts
|
|
15119
|
+
import themeCss from '@mk-kit/ui/styles.css' with { type: 'text' };
|
|
15120
|
+
mkEmbed({ styles: mkShadowCss(themeCss) });
|
|
15121
|
+
```
|
|
15122
|
+
|
|
15123
|
+
```ts
|
|
15124
|
+
function mkShadowCss(css: string): string
|
|
15125
|
+
```
|
|
15126
|
+
|
|
15127
|
+
### MkEmbedInit (interface)
|
|
15128
|
+
|
|
15129
|
+
Import: `import { MkEmbedInit } from '@mk-kit/ui/embed';`
|
|
15130
|
+
|
|
15131
|
+
Options for `mkEmbed`.
|
|
15132
|
+
|
|
15133
|
+
Members:
|
|
15134
|
+
|
|
15135
|
+
| Name | Type | Description |
|
|
15136
|
+
| --- | --- | --- |
|
|
15137
|
+
| `styles`? | `string \| readonly string[] \| undefined` | CSS text adopted into every element's shadow root (and the overlay host). Pass the mk-kit theme through `mkShadowCss` so its `:root` token blocks target `:host`; append your own widget CSS after it. Shared as constructable stylesheets when the browser supports them (one parse for any number of instances), `<style>` elements otherwise. |
|
|
15138
|
+
| `providers`? | `(Provider \| EnvironmentProviders)[] \| undefined` | Extra providers for the shared application — `provideMkI18n(…)`, `provideMkExtendedIcons()`, `provideHttpClient()`, your services. |
|
|
15139
|
+
| `overlays`? | `boolean \| undefined` | Mount mk-kit overlays (dialogs, anchored panels, toasts, tours) inside a page-level shadow host that carries the same `styles`, instead of bare `document.body`. Default `true`; set `false` to keep the application default (overlays styled by the page's own stylesheets). |
|
|
15140
|
+
|
|
15141
|
+
## @mk-kit/ui/locales/de
|
|
15142
|
+
|
|
15143
|
+
6 exports. `import { … } from '@mk-kit/ui/locales/de';`
|
|
15144
|
+
|
|
15145
|
+
### mkPluralDe (function)
|
|
15146
|
+
|
|
15147
|
+
Import: `import { mkPluralDe } from '@mk-kit/ui/locales/de';`
|
|
15148
|
+
|
|
15149
|
+
Picks the German plural form for a count — CLDR's `de` rules for integers:
|
|
15150
|
+
`one` for 1, `other` for everything else.
|
|
15151
|
+
|
|
15152
|
+
```ts
|
|
15153
|
+
mkPluralDe(1, 'Ergebnis', 'Ergebnisse'); // 'Ergebnis'
|
|
15154
|
+
mkPluralDe(3, 'Ergebnis', 'Ergebnisse'); // 'Ergebnisse'
|
|
15155
|
+
```
|
|
15156
|
+
|
|
15157
|
+
```ts
|
|
15158
|
+
function mkPluralDe(count: number, one: string, other: string): string
|
|
15159
|
+
```
|
|
15160
|
+
|
|
15161
|
+
### provideMkI18nDe (function)
|
|
15162
|
+
|
|
15163
|
+
Import: `import { provideMkI18nDe } from '@mk-kit/ui/locales/de';`
|
|
15164
|
+
|
|
15165
|
+
Provides the German strings — `MK_DE_I18N` with any `overrides`
|
|
15166
|
+
merged on top (deep for `dateNames`, `blockEditor` and `validation`, like
|
|
15167
|
+
`provideMkI18n`).
|
|
15168
|
+
|
|
15169
|
+
```ts
|
|
15170
|
+
bootstrapApplication(App, {
|
|
15171
|
+
providers: [provideMkI18nDe({ noData: 'Nichts zu sehen' })],
|
|
15172
|
+
});
|
|
15173
|
+
```
|
|
15174
|
+
|
|
15175
|
+
```ts
|
|
15176
|
+
function provideMkI18nDe(overrides?: MkI18nOverrides): Provider
|
|
15177
|
+
```
|
|
15178
|
+
|
|
15179
|
+
### MK_DE_BLOCK_EDITOR (const)
|
|
15180
|
+
|
|
15181
|
+
Import: `import { MK_DE_BLOCK_EDITOR } from '@mk-kit/ui/locales/de';`
|
|
15182
|
+
|
|
15183
|
+
German strings of the block editor's chrome.
|
|
15184
|
+
|
|
15185
|
+
```ts
|
|
15186
|
+
const MK_DE_BLOCK_EDITOR: MkBlockEditorStrings;
|
|
15187
|
+
```
|
|
15188
|
+
|
|
15189
|
+
### MK_DE_DATE_NAMES (const)
|
|
15190
|
+
|
|
15191
|
+
Import: `import { MK_DE_DATE_NAMES } from '@mk-kit/ui/locales/de';`
|
|
15192
|
+
|
|
15193
|
+
German month and weekday names (Sunday-first, as in `Intl`).
|
|
15194
|
+
|
|
15195
|
+
```ts
|
|
15196
|
+
const MK_DE_DATE_NAMES: MkDateNames;
|
|
15197
|
+
```
|
|
15198
|
+
|
|
15199
|
+
### MK_DE_I18N (const)
|
|
15200
|
+
|
|
15201
|
+
Import: `import { MK_DE_I18N } from '@mk-kit/ui/locales/de';`
|
|
15202
|
+
|
|
15203
|
+
The complete German string map — every key of `MkI18nStrings`,
|
|
15204
|
+
`locale: 'de-DE'` and `currency: 'EUR'` for the formatting pipes.
|
|
15205
|
+
Provide it whole with `provideMkI18nDe`, or pass it as the base of
|
|
15206
|
+
`provideMkI18n(overrides, MK_DE_I18N)`.
|
|
15207
|
+
|
|
15208
|
+
```ts
|
|
15209
|
+
const MK_DE_I18N: MkI18nStrings;
|
|
15210
|
+
```
|
|
15211
|
+
|
|
15212
|
+
### MK_DE_VALIDATION (const)
|
|
15213
|
+
|
|
15214
|
+
Import: `import { MK_DE_VALIDATION } from '@mk-kit/ui/locales/de';`
|
|
15215
|
+
|
|
15216
|
+
German validation messages rendered by `mk-form-field`.
|
|
15217
|
+
|
|
15218
|
+
```ts
|
|
15219
|
+
const MK_DE_VALIDATION: MkValidationStrings;
|
|
15220
|
+
```
|
|
15221
|
+
|
|
15222
|
+
## @mk-kit/ui/locales/es
|
|
15223
|
+
|
|
15224
|
+
6 exports. `import { … } from '@mk-kit/ui/locales/es';`
|
|
15225
|
+
|
|
15226
|
+
### mkPluralEs (function)
|
|
15227
|
+
|
|
15228
|
+
Import: `import { mkPluralEs } from '@mk-kit/ui/locales/es';`
|
|
15229
|
+
|
|
15230
|
+
Picks the Spanish plural form for a count — CLDR's `es` rules for integers:
|
|
15231
|
+
`one` for 1, `other` for everything else.
|
|
15232
|
+
|
|
15233
|
+
```ts
|
|
15234
|
+
mkPluralEs(1, 'resultado', 'resultados'); // 'resultado'
|
|
15235
|
+
mkPluralEs(3, 'resultado', 'resultados'); // 'resultados'
|
|
15236
|
+
```
|
|
15237
|
+
|
|
15238
|
+
```ts
|
|
15239
|
+
function mkPluralEs(count: number, one: string, other: string): string
|
|
15240
|
+
```
|
|
15241
|
+
|
|
15242
|
+
### provideMkI18nEs (function)
|
|
15243
|
+
|
|
15244
|
+
Import: `import { provideMkI18nEs } from '@mk-kit/ui/locales/es';`
|
|
15245
|
+
|
|
15246
|
+
Provides the Spanish strings — `MK_ES_I18N` with any `overrides`
|
|
15247
|
+
merged on top (deep for `dateNames`, `blockEditor` and `validation`, like
|
|
15248
|
+
`provideMkI18n`).
|
|
15249
|
+
|
|
15250
|
+
```ts
|
|
15251
|
+
bootstrapApplication(App, {
|
|
15252
|
+
providers: [provideMkI18nEs({ noData: 'No hay nada aquí' })],
|
|
15253
|
+
});
|
|
15254
|
+
```
|
|
15255
|
+
|
|
15256
|
+
```ts
|
|
15257
|
+
function provideMkI18nEs(overrides?: MkI18nOverrides): Provider
|
|
15258
|
+
```
|
|
15259
|
+
|
|
15260
|
+
### MK_ES_BLOCK_EDITOR (const)
|
|
15261
|
+
|
|
15262
|
+
Import: `import { MK_ES_BLOCK_EDITOR } from '@mk-kit/ui/locales/es';`
|
|
15263
|
+
|
|
15264
|
+
Spanish strings of the block editor's chrome.
|
|
15265
|
+
|
|
15266
|
+
```ts
|
|
15267
|
+
const MK_ES_BLOCK_EDITOR: MkBlockEditorStrings;
|
|
15268
|
+
```
|
|
15269
|
+
|
|
15270
|
+
### MK_ES_DATE_NAMES (const)
|
|
15271
|
+
|
|
15272
|
+
Import: `import { MK_ES_DATE_NAMES } from '@mk-kit/ui/locales/es';`
|
|
15273
|
+
|
|
15274
|
+
Spanish month and weekday names (Sunday-first, lowercase as in `Intl`).
|
|
15275
|
+
|
|
15276
|
+
```ts
|
|
15277
|
+
const MK_ES_DATE_NAMES: MkDateNames;
|
|
15278
|
+
```
|
|
15279
|
+
|
|
15280
|
+
### MK_ES_I18N (const)
|
|
15281
|
+
|
|
15282
|
+
Import: `import { MK_ES_I18N } from '@mk-kit/ui/locales/es';`
|
|
15283
|
+
|
|
15284
|
+
The complete Spanish string map — every key of `MkI18nStrings`,
|
|
15285
|
+
`locale: 'es-ES'` and `currency: 'EUR'` for the formatting pipes.
|
|
15286
|
+
Provide it whole with `provideMkI18nEs`, or pass it as the base of
|
|
15287
|
+
`provideMkI18n(overrides, MK_ES_I18N)`.
|
|
15288
|
+
|
|
15289
|
+
```ts
|
|
15290
|
+
const MK_ES_I18N: MkI18nStrings;
|
|
15291
|
+
```
|
|
15292
|
+
|
|
15293
|
+
### MK_ES_VALIDATION (const)
|
|
15294
|
+
|
|
15295
|
+
Import: `import { MK_ES_VALIDATION } from '@mk-kit/ui/locales/es';`
|
|
15296
|
+
|
|
15297
|
+
Spanish validation messages rendered by `mk-form-field`.
|
|
15298
|
+
|
|
15299
|
+
```ts
|
|
15300
|
+
const MK_ES_VALIDATION: MkValidationStrings;
|
|
15301
|
+
```
|
|
15302
|
+
|
|
15303
|
+
## @mk-kit/ui/locales/fr
|
|
15304
|
+
|
|
15305
|
+
6 exports. `import { … } from '@mk-kit/ui/locales/fr';`
|
|
15306
|
+
|
|
15307
|
+
### mkPluralFr (function)
|
|
15308
|
+
|
|
15309
|
+
Import: `import { mkPluralFr } from '@mk-kit/ui/locales/fr';`
|
|
15310
|
+
|
|
15311
|
+
Picks the French plural form for a count — CLDR's `fr` rules for integers:
|
|
15312
|
+
`one` for 0 and 1, `other` for everything else.
|
|
15313
|
+
|
|
15314
|
+
```ts
|
|
15315
|
+
mkPluralFr(1, 'résultat', 'résultats'); // 'résultat'
|
|
15316
|
+
mkPluralFr(0, 'résultat', 'résultats'); // 'résultat'
|
|
15317
|
+
mkPluralFr(3, 'résultat', 'résultats'); // 'résultats'
|
|
15318
|
+
```
|
|
15319
|
+
|
|
15320
|
+
```ts
|
|
15321
|
+
function mkPluralFr(count: number, one: string, other: string): string
|
|
15322
|
+
```
|
|
15323
|
+
|
|
15324
|
+
### provideMkI18nFr (function)
|
|
15325
|
+
|
|
15326
|
+
Import: `import { provideMkI18nFr } from '@mk-kit/ui/locales/fr';`
|
|
15327
|
+
|
|
15328
|
+
Provides the French strings — `MK_FR_I18N` with any `overrides`
|
|
15329
|
+
merged on top (deep for `dateNames`, `blockEditor` and `validation`, like
|
|
15330
|
+
`provideMkI18n`).
|
|
15331
|
+
|
|
15332
|
+
```ts
|
|
15333
|
+
bootstrapApplication(App, {
|
|
15334
|
+
providers: [provideMkI18nFr({ noData: 'Rien à afficher ici' })],
|
|
15335
|
+
});
|
|
15336
|
+
```
|
|
15337
|
+
|
|
15338
|
+
```ts
|
|
15339
|
+
function provideMkI18nFr(overrides?: MkI18nOverrides): Provider
|
|
15340
|
+
```
|
|
15341
|
+
|
|
15342
|
+
### MK_FR_BLOCK_EDITOR (const)
|
|
15343
|
+
|
|
15344
|
+
Import: `import { MK_FR_BLOCK_EDITOR } from '@mk-kit/ui/locales/fr';`
|
|
15345
|
+
|
|
15346
|
+
French strings of the block editor's chrome.
|
|
15347
|
+
|
|
15348
|
+
```ts
|
|
15349
|
+
const MK_FR_BLOCK_EDITOR: MkBlockEditorStrings;
|
|
15350
|
+
```
|
|
15351
|
+
|
|
15352
|
+
### MK_FR_DATE_NAMES (const)
|
|
15353
|
+
|
|
15354
|
+
Import: `import { MK_FR_DATE_NAMES } from '@mk-kit/ui/locales/fr';`
|
|
15355
|
+
|
|
15356
|
+
French month and weekday names (Sunday-first, lowercase as in `Intl`).
|
|
15357
|
+
|
|
15358
|
+
```ts
|
|
15359
|
+
const MK_FR_DATE_NAMES: MkDateNames;
|
|
15360
|
+
```
|
|
15361
|
+
|
|
15362
|
+
### MK_FR_I18N (const)
|
|
15363
|
+
|
|
15364
|
+
Import: `import { MK_FR_I18N } from '@mk-kit/ui/locales/fr';`
|
|
15365
|
+
|
|
15366
|
+
The complete French string map — every key of `MkI18nStrings`,
|
|
15367
|
+
`locale: 'fr-FR'` and `currency: 'EUR'` for the formatting pipes.
|
|
15368
|
+
Provide it whole with `provideMkI18nFr`, or pass it as the base of
|
|
15369
|
+
`provideMkI18n(overrides, MK_FR_I18N)`.
|
|
15370
|
+
|
|
15371
|
+
```ts
|
|
15372
|
+
const MK_FR_I18N: MkI18nStrings;
|
|
15373
|
+
```
|
|
15374
|
+
|
|
15375
|
+
### MK_FR_VALIDATION (const)
|
|
15376
|
+
|
|
15377
|
+
Import: `import { MK_FR_VALIDATION } from '@mk-kit/ui/locales/fr';`
|
|
15378
|
+
|
|
15379
|
+
French validation messages rendered by `mk-form-field`.
|
|
15380
|
+
|
|
15381
|
+
```ts
|
|
15382
|
+
const MK_FR_VALIDATION: MkValidationStrings;
|
|
15383
|
+
```
|
|
15384
|
+
|
|
15004
15385
|
## @mk-kit/ui/locales/pl
|
|
15005
15386
|
|
|
15006
15387
|
6 exports. `import { … } from '@mk-kit/ui/locales/pl';`
|
|
@@ -15084,6 +15465,89 @@ Polish validation messages rendered by `mk-form-field`.
|
|
|
15084
15465
|
const MK_PL_VALIDATION: MkValidationStrings;
|
|
15085
15466
|
```
|
|
15086
15467
|
|
|
15468
|
+
## @mk-kit/ui/locales/uk
|
|
15469
|
+
|
|
15470
|
+
6 exports. `import { … } from '@mk-kit/ui/locales/uk';`
|
|
15471
|
+
|
|
15472
|
+
### mkPluralUk (function)
|
|
15473
|
+
|
|
15474
|
+
Import: `import { mkPluralUk } from '@mk-kit/ui/locales/uk';`
|
|
15475
|
+
|
|
15476
|
+
Picks the Ukrainian plural form for a count — CLDR's `uk` rules for
|
|
15477
|
+
integers: `one` when the number ends in 1 (but not 11), `few` when it ends
|
|
15478
|
+
in 2–4 (but not 12–14), `many` otherwise.
|
|
15479
|
+
|
|
15480
|
+
```ts
|
|
15481
|
+
mkPluralUk(1, 'результат', 'результати', 'результатів'); // 'результат'
|
|
15482
|
+
mkPluralUk(3, 'результат', 'результати', 'результатів'); // 'результати'
|
|
15483
|
+
mkPluralUk(11, 'результат', 'результати', 'результатів'); // 'результатів'
|
|
15484
|
+
```
|
|
15485
|
+
|
|
15486
|
+
```ts
|
|
15487
|
+
function mkPluralUk(count: number, one: string, few: string, many: string): string
|
|
15488
|
+
```
|
|
15489
|
+
|
|
15490
|
+
### provideMkI18nUk (function)
|
|
15491
|
+
|
|
15492
|
+
Import: `import { provideMkI18nUk } from '@mk-kit/ui/locales/uk';`
|
|
15493
|
+
|
|
15494
|
+
Provides the Ukrainian strings — `MK_UK_I18N` with any `overrides`
|
|
15495
|
+
merged on top (deep for `dateNames`, `blockEditor` and `validation`, like
|
|
15496
|
+
`provideMkI18n`).
|
|
15497
|
+
|
|
15498
|
+
```ts
|
|
15499
|
+
bootstrapApplication(App, {
|
|
15500
|
+
providers: [provideMkI18nUk({ noData: 'Тут нічого немає' })],
|
|
15501
|
+
});
|
|
15502
|
+
```
|
|
15503
|
+
|
|
15504
|
+
```ts
|
|
15505
|
+
function provideMkI18nUk(overrides?: MkI18nOverrides): Provider
|
|
15506
|
+
```
|
|
15507
|
+
|
|
15508
|
+
### MK_UK_BLOCK_EDITOR (const)
|
|
15509
|
+
|
|
15510
|
+
Import: `import { MK_UK_BLOCK_EDITOR } from '@mk-kit/ui/locales/uk';`
|
|
15511
|
+
|
|
15512
|
+
Ukrainian strings of the block editor's chrome.
|
|
15513
|
+
|
|
15514
|
+
```ts
|
|
15515
|
+
const MK_UK_BLOCK_EDITOR: MkBlockEditorStrings;
|
|
15516
|
+
```
|
|
15517
|
+
|
|
15518
|
+
### MK_UK_DATE_NAMES (const)
|
|
15519
|
+
|
|
15520
|
+
Import: `import { MK_UK_DATE_NAMES } from '@mk-kit/ui/locales/uk';`
|
|
15521
|
+
|
|
15522
|
+
Ukrainian month and weekday names (Sunday-first, lowercase as in `Intl`).
|
|
15523
|
+
|
|
15524
|
+
```ts
|
|
15525
|
+
const MK_UK_DATE_NAMES: MkDateNames;
|
|
15526
|
+
```
|
|
15527
|
+
|
|
15528
|
+
### MK_UK_I18N (const)
|
|
15529
|
+
|
|
15530
|
+
Import: `import { MK_UK_I18N } from '@mk-kit/ui/locales/uk';`
|
|
15531
|
+
|
|
15532
|
+
The complete Ukrainian string map — every key of `MkI18nStrings`,
|
|
15533
|
+
`locale: 'uk-UA'` and `currency: 'UAH'` for the formatting pipes.
|
|
15534
|
+
Provide it whole with `provideMkI18nUk`, or pass it as the base of
|
|
15535
|
+
`provideMkI18n(overrides, MK_UK_I18N)`.
|
|
15536
|
+
|
|
15537
|
+
```ts
|
|
15538
|
+
const MK_UK_I18N: MkI18nStrings;
|
|
15539
|
+
```
|
|
15540
|
+
|
|
15541
|
+
### MK_UK_VALIDATION (const)
|
|
15542
|
+
|
|
15543
|
+
Import: `import { MK_UK_VALIDATION } from '@mk-kit/ui/locales/uk';`
|
|
15544
|
+
|
|
15545
|
+
Ukrainian validation messages rendered by `mk-form-field`.
|
|
15546
|
+
|
|
15547
|
+
```ts
|
|
15548
|
+
const MK_UK_VALIDATION: MkValidationStrings;
|
|
15549
|
+
```
|
|
15550
|
+
|
|
15087
15551
|
## @mk-kit/ui/testing
|
|
15088
15552
|
|
|
15089
15553
|
23 exports. `import { … } from '@mk-kit/ui/testing';`
|
package/data/llms.txt
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# mk-kit
|
|
2
2
|
|
|
3
|
-
> Themable, accessible Angular 22 component library for admin dashboards and UIs. Signals-based, WCAG 2.1 AA, controlled entirely through CSS variables with light/dark out of the box. — `@mk-kit/ui` 0.
|
|
3
|
+
> Themable, accessible Angular 22 component library for admin dashboards and UIs. Signals-based, WCAG 2.1 AA, controlled entirely through CSS variables with light/dark out of the box. — `@mk-kit/ui` 0.48.0. 170 components, 41 directives, 16 services and 144 helper functions across 29 tree-shakeable entry points. MIT licensed, zero runtime dependencies beyond Angular. Standalone components, signals, OnPush, zoneless-ready, SSR-safe, RTL and i18n via `provideMkI18n`.
|
|
4
4
|
|
|
5
5
|
Install with `ng add @mk-kit/ui` (or `npm i @mk-kit/ui` + import `@mk-kit/ui/styles/mk-kit.css`). Import from the group entry points (`@mk-kit/ui/forms`, `@mk-kit/ui/table`, …) so each lazy chunk only carries what it uses; the root `@mk-kit/ui` entry re-exports everything. Every component is standalone: add the class to a component's `imports`. Theme with `--mk-*` CSS custom properties; `MkThemeService` switches light/dark/system and density.
|
|
6
6
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mk-kit/mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.48.0",
|
|
4
4
|
"description": "MCP server for @mk-kit/ui — lets AI coding assistants look up every component, directive, service and helper of the mk-kit Angular library (inputs, outputs, methods, import paths, docs links).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|