@frontmcp/ui 0.6.0 → 0.6.2
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 +140 -362
- package/bridge/core/bridge-factory.d.ts +1 -0
- package/bridge/core/bridge-factory.d.ts.map +1 -1
- package/bridge/index.d.ts +1 -1
- package/bridge/index.d.ts.map +1 -1
- package/bridge/index.js +39 -881
- package/bridge/runtime/index.d.ts +2 -1
- package/bridge/runtime/index.d.ts.map +1 -1
- package/bundler/browser-components.d.ts +42 -0
- package/bundler/browser-components.d.ts.map +1 -0
- package/bundler/bundler.d.ts +78 -4
- package/bundler/bundler.d.ts.map +1 -1
- package/bundler/index.d.ts +8 -8
- package/bundler/index.d.ts.map +1 -1
- package/bundler/index.js +1411 -2997
- package/bundler/types.d.ts +188 -7
- package/bundler/types.d.ts.map +1 -1
- package/components/alert.schema.d.ts +6 -6
- package/components/avatar.schema.d.ts +9 -9
- package/components/badge.schema.d.ts +9 -9
- package/components/button.schema.d.ts +9 -9
- package/components/card.schema.d.ts +7 -7
- package/components/form.schema.d.ts +24 -24
- package/components/index.js +128 -198
- package/components/modal.schema.d.ts +8 -8
- package/components/table.schema.d.ts +6 -6
- package/esm/bridge/{index.js → index.mjs} +40 -877
- package/esm/bundler/index.mjs +3136 -0
- package/esm/components/{index.js → index.mjs} +136 -196
- package/esm/index.mjs +5450 -0
- package/esm/layouts/index.mjs +409 -0
- package/esm/package.json +15 -32
- package/esm/react/{index.js → index.mjs} +71 -260
- package/esm/renderers/index.mjs +611 -0
- package/esm/universal/index.mjs +1951 -0
- package/esm/web-components/{index.js → index.mjs} +232 -287
- package/index.d.ts +22 -41
- package/index.d.ts.map +1 -1
- package/index.js +4286 -19607
- package/layouts/base.d.ts +2 -2
- package/layouts/base.d.ts.map +1 -1
- package/layouts/index.js +46 -539
- package/layouts/presets.d.ts.map +1 -1
- package/package.json +15 -32
- package/react/Alert.d.ts +1 -2
- package/react/Alert.d.ts.map +1 -1
- package/react/Badge.d.ts +1 -2
- package/react/Badge.d.ts.map +1 -1
- package/react/Button.d.ts +1 -2
- package/react/Button.d.ts.map +1 -1
- package/react/Card.d.ts +1 -2
- package/react/Card.d.ts.map +1 -1
- package/react/hooks/context.d.ts +1 -1
- package/react/hooks/context.d.ts.map +1 -1
- package/react/index.d.ts +5 -7
- package/react/index.d.ts.map +1 -1
- package/react/index.js +55 -269
- package/react/types.d.ts +1 -2
- package/react/types.d.ts.map +1 -1
- package/renderers/index.d.ts +15 -25
- package/renderers/index.d.ts.map +1 -1
- package/renderers/index.js +393 -1619
- package/renderers/mdx.renderer.d.ts +13 -34
- package/renderers/mdx.renderer.d.ts.map +1 -1
- package/{esm/runtime/adapters → renderers}/react.adapter.d.ts +2 -2
- package/renderers/react.adapter.d.ts.map +1 -0
- package/renderers/react.renderer.d.ts +25 -16
- package/renderers/react.renderer.d.ts.map +1 -1
- package/renderers/transpiler.d.ts +49 -0
- package/renderers/transpiler.d.ts.map +1 -0
- package/universal/cached-runtime.d.ts +25 -1
- package/universal/cached-runtime.d.ts.map +1 -1
- package/universal/index.js +2037 -0
- package/universal/runtime-builder.d.ts.map +1 -1
- package/universal/types.d.ts.map +1 -1
- package/web-components/elements/fmcp-input.d.ts.map +1 -1
- package/web-components/elements/fmcp-select.d.ts.map +1 -1
- package/web-components/index.d.ts +0 -1
- package/web-components/index.d.ts.map +1 -1
- package/web-components/index.js +224 -289
- package/adapters/index.d.ts +0 -13
- package/adapters/index.d.ts.map +0 -1
- package/adapters/index.js +0 -462
- package/adapters/platform-meta.d.ts +0 -166
- package/adapters/platform-meta.d.ts.map +0 -1
- package/adapters/response-builder.d.ts +0 -108
- package/adapters/response-builder.d.ts.map +0 -1
- package/adapters/serving-mode.d.ts +0 -107
- package/adapters/serving-mode.d.ts.map +0 -1
- package/base-template/bridge.d.ts +0 -90
- package/base-template/bridge.d.ts.map +0 -1
- package/base-template/default-base-template.d.ts +0 -92
- package/base-template/default-base-template.d.ts.map +0 -1
- package/base-template/index.d.ts +0 -15
- package/base-template/index.d.ts.map +0 -1
- package/base-template/index.js +0 -1398
- package/base-template/polyfills.d.ts +0 -31
- package/base-template/polyfills.d.ts.map +0 -1
- package/base-template/theme-styles.d.ts +0 -74
- package/base-template/theme-styles.d.ts.map +0 -1
- package/build/cdn-resources.d.ts +0 -243
- package/build/cdn-resources.d.ts.map +0 -1
- package/build/index.d.ts +0 -295
- package/build/index.d.ts.map +0 -1
- package/build/index.js +0 -7096
- package/build/widget-manifest.d.ts +0 -362
- package/build/widget-manifest.d.ts.map +0 -1
- package/bundler/cache.d.ts +0 -173
- package/bundler/cache.d.ts.map +0 -1
- package/bundler/file-cache/component-builder.d.ts +0 -167
- package/bundler/file-cache/component-builder.d.ts.map +0 -1
- package/bundler/file-cache/hash-calculator.d.ts +0 -155
- package/bundler/file-cache/hash-calculator.d.ts.map +0 -1
- package/bundler/file-cache/index.d.ts +0 -12
- package/bundler/file-cache/index.d.ts.map +0 -1
- package/bundler/file-cache/storage/filesystem.d.ts +0 -149
- package/bundler/file-cache/storage/filesystem.d.ts.map +0 -1
- package/bundler/file-cache/storage/index.d.ts +0 -11
- package/bundler/file-cache/storage/index.d.ts.map +0 -1
- package/bundler/file-cache/storage/interface.d.ts +0 -152
- package/bundler/file-cache/storage/interface.d.ts.map +0 -1
- package/bundler/file-cache/storage/redis.d.ts +0 -139
- package/bundler/file-cache/storage/redis.d.ts.map +0 -1
- package/bundler/sandbox/enclave-adapter.d.ts +0 -121
- package/bundler/sandbox/enclave-adapter.d.ts.map +0 -1
- package/bundler/sandbox/executor.d.ts +0 -14
- package/bundler/sandbox/executor.d.ts.map +0 -1
- package/bundler/sandbox/policy.d.ts +0 -62
- package/bundler/sandbox/policy.d.ts.map +0 -1
- package/dependency/cdn-registry.d.ts +0 -98
- package/dependency/cdn-registry.d.ts.map +0 -1
- package/dependency/import-map.d.ts +0 -186
- package/dependency/import-map.d.ts.map +0 -1
- package/dependency/import-parser.d.ts +0 -82
- package/dependency/import-parser.d.ts.map +0 -1
- package/dependency/index.d.ts +0 -17
- package/dependency/index.d.ts.map +0 -1
- package/dependency/resolver.d.ts +0 -164
- package/dependency/resolver.d.ts.map +0 -1
- package/dependency/schemas.d.ts +0 -486
- package/dependency/schemas.d.ts.map +0 -1
- package/dependency/template-loader.d.ts +0 -204
- package/dependency/template-loader.d.ts.map +0 -1
- package/dependency/template-processor.d.ts +0 -118
- package/dependency/template-processor.d.ts.map +0 -1
- package/dependency/types.d.ts +0 -739
- package/dependency/types.d.ts.map +0 -1
- package/esm/adapters/index.d.ts +0 -13
- package/esm/adapters/index.d.ts.map +0 -1
- package/esm/adapters/index.js +0 -427
- package/esm/adapters/platform-meta.d.ts +0 -166
- package/esm/adapters/platform-meta.d.ts.map +0 -1
- package/esm/adapters/response-builder.d.ts +0 -108
- package/esm/adapters/response-builder.d.ts.map +0 -1
- package/esm/adapters/serving-mode.d.ts +0 -107
- package/esm/adapters/serving-mode.d.ts.map +0 -1
- package/esm/base-template/bridge.d.ts +0 -90
- package/esm/base-template/bridge.d.ts.map +0 -1
- package/esm/base-template/default-base-template.d.ts +0 -92
- package/esm/base-template/default-base-template.d.ts.map +0 -1
- package/esm/base-template/index.d.ts +0 -15
- package/esm/base-template/index.d.ts.map +0 -1
- package/esm/base-template/index.js +0 -1364
- package/esm/base-template/polyfills.d.ts +0 -31
- package/esm/base-template/polyfills.d.ts.map +0 -1
- package/esm/base-template/theme-styles.d.ts +0 -74
- package/esm/base-template/theme-styles.d.ts.map +0 -1
- package/esm/bridge/adapters/base-adapter.d.ts +0 -104
- package/esm/bridge/adapters/base-adapter.d.ts.map +0 -1
- package/esm/bridge/adapters/claude.adapter.d.ts +0 -67
- package/esm/bridge/adapters/claude.adapter.d.ts.map +0 -1
- package/esm/bridge/adapters/ext-apps.adapter.d.ts +0 -143
- package/esm/bridge/adapters/ext-apps.adapter.d.ts.map +0 -1
- package/esm/bridge/adapters/gemini.adapter.d.ts +0 -64
- package/esm/bridge/adapters/gemini.adapter.d.ts.map +0 -1
- package/esm/bridge/adapters/generic.adapter.d.ts +0 -56
- package/esm/bridge/adapters/generic.adapter.d.ts.map +0 -1
- package/esm/bridge/adapters/index.d.ts +0 -26
- package/esm/bridge/adapters/index.d.ts.map +0 -1
- package/esm/bridge/adapters/openai.adapter.d.ts +0 -65
- package/esm/bridge/adapters/openai.adapter.d.ts.map +0 -1
- package/esm/bridge/core/adapter-registry.d.ts +0 -122
- package/esm/bridge/core/adapter-registry.d.ts.map +0 -1
- package/esm/bridge/core/bridge-factory.d.ts +0 -199
- package/esm/bridge/core/bridge-factory.d.ts.map +0 -1
- package/esm/bridge/core/index.d.ts +0 -10
- package/esm/bridge/core/index.d.ts.map +0 -1
- package/esm/bridge/index.d.ts +0 -62
- package/esm/bridge/index.d.ts.map +0 -1
- package/esm/bridge/runtime/iife-generator.d.ts +0 -62
- package/esm/bridge/runtime/iife-generator.d.ts.map +0 -1
- package/esm/bridge/runtime/index.d.ts +0 -9
- package/esm/bridge/runtime/index.d.ts.map +0 -1
- package/esm/bridge/types.d.ts +0 -386
- package/esm/bridge/types.d.ts.map +0 -1
- package/esm/build/cdn-resources.d.ts +0 -243
- package/esm/build/cdn-resources.d.ts.map +0 -1
- package/esm/build/index.d.ts +0 -295
- package/esm/build/index.d.ts.map +0 -1
- package/esm/build/index.js +0 -7021
- package/esm/build/widget-manifest.d.ts +0 -362
- package/esm/build/widget-manifest.d.ts.map +0 -1
- package/esm/bundler/bundler.d.ts +0 -208
- package/esm/bundler/bundler.d.ts.map +0 -1
- package/esm/bundler/cache.d.ts +0 -173
- package/esm/bundler/cache.d.ts.map +0 -1
- package/esm/bundler/file-cache/component-builder.d.ts +0 -167
- package/esm/bundler/file-cache/component-builder.d.ts.map +0 -1
- package/esm/bundler/file-cache/hash-calculator.d.ts +0 -155
- package/esm/bundler/file-cache/hash-calculator.d.ts.map +0 -1
- package/esm/bundler/file-cache/index.d.ts +0 -12
- package/esm/bundler/file-cache/index.d.ts.map +0 -1
- package/esm/bundler/file-cache/storage/filesystem.d.ts +0 -149
- package/esm/bundler/file-cache/storage/filesystem.d.ts.map +0 -1
- package/esm/bundler/file-cache/storage/index.d.ts +0 -11
- package/esm/bundler/file-cache/storage/index.d.ts.map +0 -1
- package/esm/bundler/file-cache/storage/interface.d.ts +0 -152
- package/esm/bundler/file-cache/storage/interface.d.ts.map +0 -1
- package/esm/bundler/file-cache/storage/redis.d.ts +0 -139
- package/esm/bundler/file-cache/storage/redis.d.ts.map +0 -1
- package/esm/bundler/index.d.ts +0 -43
- package/esm/bundler/index.d.ts.map +0 -1
- package/esm/bundler/index.js +0 -4687
- package/esm/bundler/sandbox/enclave-adapter.d.ts +0 -121
- package/esm/bundler/sandbox/enclave-adapter.d.ts.map +0 -1
- package/esm/bundler/sandbox/executor.d.ts +0 -14
- package/esm/bundler/sandbox/executor.d.ts.map +0 -1
- package/esm/bundler/sandbox/policy.d.ts +0 -62
- package/esm/bundler/sandbox/policy.d.ts.map +0 -1
- package/esm/bundler/types.d.ts +0 -702
- package/esm/bundler/types.d.ts.map +0 -1
- package/esm/components/alert.d.ts +0 -66
- package/esm/components/alert.d.ts.map +0 -1
- package/esm/components/alert.schema.d.ts +0 -98
- package/esm/components/alert.schema.d.ts.map +0 -1
- package/esm/components/avatar.d.ts +0 -77
- package/esm/components/avatar.d.ts.map +0 -1
- package/esm/components/avatar.schema.d.ts +0 -170
- package/esm/components/avatar.schema.d.ts.map +0 -1
- package/esm/components/badge.d.ts +0 -64
- package/esm/components/badge.d.ts.map +0 -1
- package/esm/components/badge.schema.d.ts +0 -91
- package/esm/components/badge.schema.d.ts.map +0 -1
- package/esm/components/button.d.ts +0 -100
- package/esm/components/button.d.ts.map +0 -1
- package/esm/components/button.schema.d.ts +0 -120
- package/esm/components/button.schema.d.ts.map +0 -1
- package/esm/components/card.d.ts +0 -53
- package/esm/components/card.d.ts.map +0 -1
- package/esm/components/card.schema.d.ts +0 -93
- package/esm/components/card.schema.d.ts.map +0 -1
- package/esm/components/form.d.ts +0 -212
- package/esm/components/form.d.ts.map +0 -1
- package/esm/components/form.schema.d.ts +0 -365
- package/esm/components/form.schema.d.ts.map +0 -1
- package/esm/components/index.d.ts +0 -29
- package/esm/components/index.d.ts.map +0 -1
- package/esm/components/list.d.ts +0 -121
- package/esm/components/list.d.ts.map +0 -1
- package/esm/components/list.schema.d.ts +0 -129
- package/esm/components/list.schema.d.ts.map +0 -1
- package/esm/components/modal.d.ts +0 -100
- package/esm/components/modal.d.ts.map +0 -1
- package/esm/components/modal.schema.d.ts +0 -151
- package/esm/components/modal.schema.d.ts.map +0 -1
- package/esm/components/table.d.ts +0 -91
- package/esm/components/table.d.ts.map +0 -1
- package/esm/components/table.schema.d.ts +0 -123
- package/esm/components/table.schema.d.ts.map +0 -1
- package/esm/dependency/cdn-registry.d.ts +0 -98
- package/esm/dependency/cdn-registry.d.ts.map +0 -1
- package/esm/dependency/import-map.d.ts +0 -186
- package/esm/dependency/import-map.d.ts.map +0 -1
- package/esm/dependency/import-parser.d.ts +0 -82
- package/esm/dependency/import-parser.d.ts.map +0 -1
- package/esm/dependency/index.d.ts +0 -17
- package/esm/dependency/index.d.ts.map +0 -1
- package/esm/dependency/resolver.d.ts +0 -164
- package/esm/dependency/resolver.d.ts.map +0 -1
- package/esm/dependency/schemas.d.ts +0 -486
- package/esm/dependency/schemas.d.ts.map +0 -1
- package/esm/dependency/template-loader.d.ts +0 -204
- package/esm/dependency/template-loader.d.ts.map +0 -1
- package/esm/dependency/template-processor.d.ts +0 -118
- package/esm/dependency/template-processor.d.ts.map +0 -1
- package/esm/dependency/types.d.ts +0 -739
- package/esm/dependency/types.d.ts.map +0 -1
- package/esm/handlebars/expression-extractor.d.ts +0 -147
- package/esm/handlebars/expression-extractor.d.ts.map +0 -1
- package/esm/handlebars/helpers.d.ts +0 -339
- package/esm/handlebars/helpers.d.ts.map +0 -1
- package/esm/handlebars/index.d.ts +0 -195
- package/esm/handlebars/index.d.ts.map +0 -1
- package/esm/handlebars/index.js +0 -587
- package/esm/index.d.ts +0 -56
- package/esm/index.d.ts.map +0 -1
- package/esm/index.js +0 -20511
- package/esm/layouts/base.d.ts +0 -86
- package/esm/layouts/base.d.ts.map +0 -1
- package/esm/layouts/index.d.ts +0 -8
- package/esm/layouts/index.d.ts.map +0 -1
- package/esm/layouts/index.js +0 -892
- package/esm/layouts/presets.d.ts +0 -134
- package/esm/layouts/presets.d.ts.map +0 -1
- package/esm/pages/consent.d.ts +0 -117
- package/esm/pages/consent.d.ts.map +0 -1
- package/esm/pages/error.d.ts +0 -101
- package/esm/pages/error.d.ts.map +0 -1
- package/esm/pages/index.d.ts +0 -9
- package/esm/pages/index.d.ts.map +0 -1
- package/esm/pages/index.js +0 -1563
- package/esm/react/Alert.d.ts +0 -102
- package/esm/react/Alert.d.ts.map +0 -1
- package/esm/react/Badge.d.ts +0 -101
- package/esm/react/Badge.d.ts.map +0 -1
- package/esm/react/Button.d.ts +0 -109
- package/esm/react/Button.d.ts.map +0 -1
- package/esm/react/Card.d.ts +0 -104
- package/esm/react/Card.d.ts.map +0 -1
- package/esm/react/hooks/context.d.ts +0 -179
- package/esm/react/hooks/context.d.ts.map +0 -1
- package/esm/react/hooks/index.d.ts +0 -42
- package/esm/react/hooks/index.d.ts.map +0 -1
- package/esm/react/hooks/tools.d.ts +0 -284
- package/esm/react/hooks/tools.d.ts.map +0 -1
- package/esm/react/index.d.ts +0 -81
- package/esm/react/index.d.ts.map +0 -1
- package/esm/react/types.d.ts +0 -106
- package/esm/react/types.d.ts.map +0 -1
- package/esm/react/utils.d.ts +0 -43
- package/esm/react/utils.d.ts.map +0 -1
- package/esm/registry/index.d.ts +0 -46
- package/esm/registry/index.d.ts.map +0 -1
- package/esm/registry/index.js +0 -6422
- package/esm/registry/render-template.d.ts +0 -91
- package/esm/registry/render-template.d.ts.map +0 -1
- package/esm/registry/tool-ui.registry.d.ts +0 -294
- package/esm/registry/tool-ui.registry.d.ts.map +0 -1
- package/esm/registry/uri-utils.d.ts +0 -56
- package/esm/registry/uri-utils.d.ts.map +0 -1
- package/esm/render/index.d.ts +0 -8
- package/esm/render/index.d.ts.map +0 -1
- package/esm/render/prerender.d.ts +0 -57
- package/esm/render/prerender.d.ts.map +0 -1
- package/esm/renderers/cache.d.ts +0 -145
- package/esm/renderers/cache.d.ts.map +0 -1
- package/esm/renderers/html.renderer.d.ts +0 -123
- package/esm/renderers/html.renderer.d.ts.map +0 -1
- package/esm/renderers/index.d.ts +0 -36
- package/esm/renderers/index.d.ts.map +0 -1
- package/esm/renderers/index.js +0 -1827
- package/esm/renderers/mdx.renderer.d.ts +0 -120
- package/esm/renderers/mdx.renderer.d.ts.map +0 -1
- package/esm/renderers/react.renderer.d.ts +0 -96
- package/esm/renderers/react.renderer.d.ts.map +0 -1
- package/esm/renderers/registry.d.ts +0 -134
- package/esm/renderers/registry.d.ts.map +0 -1
- package/esm/renderers/types.d.ts +0 -342
- package/esm/renderers/types.d.ts.map +0 -1
- package/esm/renderers/utils/detect.d.ts +0 -107
- package/esm/renderers/utils/detect.d.ts.map +0 -1
- package/esm/renderers/utils/hash.d.ts +0 -40
- package/esm/renderers/utils/hash.d.ts.map +0 -1
- package/esm/renderers/utils/index.d.ts +0 -9
- package/esm/renderers/utils/index.d.ts.map +0 -1
- package/esm/renderers/utils/transpiler.d.ts +0 -89
- package/esm/renderers/utils/transpiler.d.ts.map +0 -1
- package/esm/runtime/adapters/html.adapter.d.ts +0 -59
- package/esm/runtime/adapters/html.adapter.d.ts.map +0 -1
- package/esm/runtime/adapters/index.d.ts +0 -26
- package/esm/runtime/adapters/index.d.ts.map +0 -1
- package/esm/runtime/adapters/mdx.adapter.d.ts +0 -73
- package/esm/runtime/adapters/mdx.adapter.d.ts.map +0 -1
- package/esm/runtime/adapters/react.adapter.d.ts.map +0 -1
- package/esm/runtime/adapters/types.d.ts +0 -95
- package/esm/runtime/adapters/types.d.ts.map +0 -1
- package/esm/runtime/csp.d.ts +0 -48
- package/esm/runtime/csp.d.ts.map +0 -1
- package/esm/runtime/index.d.ts +0 -17
- package/esm/runtime/index.d.ts.map +0 -1
- package/esm/runtime/index.js +0 -5186
- package/esm/runtime/mcp-bridge.d.ts +0 -101
- package/esm/runtime/mcp-bridge.d.ts.map +0 -1
- package/esm/runtime/renderer-runtime.d.ts +0 -133
- package/esm/runtime/renderer-runtime.d.ts.map +0 -1
- package/esm/runtime/sanitizer.d.ts +0 -172
- package/esm/runtime/sanitizer.d.ts.map +0 -1
- package/esm/runtime/types.d.ts +0 -415
- package/esm/runtime/types.d.ts.map +0 -1
- package/esm/runtime/wrapper.d.ts +0 -421
- package/esm/runtime/wrapper.d.ts.map +0 -1
- package/esm/styles/index.d.ts +0 -8
- package/esm/styles/index.d.ts.map +0 -1
- package/esm/styles/index.js +0 -171
- package/esm/styles/variants.d.ts +0 -51
- package/esm/styles/variants.d.ts.map +0 -1
- package/esm/theme/cdn.d.ts +0 -195
- package/esm/theme/cdn.d.ts.map +0 -1
- package/esm/theme/index.d.ts +0 -18
- package/esm/theme/index.d.ts.map +0 -1
- package/esm/theme/index.js +0 -700
- package/esm/theme/platforms.d.ts +0 -107
- package/esm/theme/platforms.d.ts.map +0 -1
- package/esm/theme/presets/github-openai.d.ts +0 -50
- package/esm/theme/presets/github-openai.d.ts.map +0 -1
- package/esm/theme/presets/index.d.ts +0 -11
- package/esm/theme/presets/index.d.ts.map +0 -1
- package/esm/theme/theme.d.ts +0 -396
- package/esm/theme/theme.d.ts.map +0 -1
- package/esm/tool-template/builder.d.ts +0 -213
- package/esm/tool-template/builder.d.ts.map +0 -1
- package/esm/tool-template/index.d.ts +0 -16
- package/esm/tool-template/index.d.ts.map +0 -1
- package/esm/tool-template/index.js +0 -3515
- package/esm/types/index.d.ts +0 -14
- package/esm/types/index.d.ts.map +0 -1
- package/esm/types/index.js +0 -75
- package/esm/types/ui-config.d.ts +0 -639
- package/esm/types/ui-config.d.ts.map +0 -1
- package/esm/types/ui-runtime.d.ts +0 -1007
- package/esm/types/ui-runtime.d.ts.map +0 -1
- package/esm/typings/cache/cache-adapter.d.ts +0 -125
- package/esm/typings/cache/cache-adapter.d.ts.map +0 -1
- package/esm/typings/cache/index.d.ts +0 -10
- package/esm/typings/cache/index.d.ts.map +0 -1
- package/esm/typings/cache/memory-cache.d.ts +0 -92
- package/esm/typings/cache/memory-cache.d.ts.map +0 -1
- package/esm/typings/dts-parser.d.ts +0 -90
- package/esm/typings/dts-parser.d.ts.map +0 -1
- package/esm/typings/index.d.ts +0 -48
- package/esm/typings/index.d.ts.map +0 -1
- package/esm/typings/schemas.d.ts +0 -232
- package/esm/typings/schemas.d.ts.map +0 -1
- package/esm/typings/type-fetcher.d.ts +0 -89
- package/esm/typings/type-fetcher.d.ts.map +0 -1
- package/esm/typings/types.d.ts +0 -320
- package/esm/typings/types.d.ts.map +0 -1
- package/esm/universal/UniversalApp.d.ts +0 -108
- package/esm/universal/UniversalApp.d.ts.map +0 -1
- package/esm/universal/cached-runtime.d.ts +0 -115
- package/esm/universal/cached-runtime.d.ts.map +0 -1
- package/esm/universal/context.d.ts +0 -122
- package/esm/universal/context.d.ts.map +0 -1
- package/esm/universal/index.d.ts +0 -57
- package/esm/universal/index.d.ts.map +0 -1
- package/esm/universal/renderers/html.renderer.d.ts +0 -37
- package/esm/universal/renderers/html.renderer.d.ts.map +0 -1
- package/esm/universal/renderers/index.d.ts +0 -112
- package/esm/universal/renderers/index.d.ts.map +0 -1
- package/esm/universal/renderers/markdown.renderer.d.ts +0 -33
- package/esm/universal/renderers/markdown.renderer.d.ts.map +0 -1
- package/esm/universal/renderers/mdx.renderer.d.ts +0 -38
- package/esm/universal/renderers/mdx.renderer.d.ts.map +0 -1
- package/esm/universal/renderers/react.renderer.d.ts +0 -46
- package/esm/universal/renderers/react.renderer.d.ts.map +0 -1
- package/esm/universal/runtime-builder.d.ts +0 -33
- package/esm/universal/runtime-builder.d.ts.map +0 -1
- package/esm/universal/store.d.ts +0 -135
- package/esm/universal/store.d.ts.map +0 -1
- package/esm/universal/types.d.ts +0 -199
- package/esm/universal/types.d.ts.map +0 -1
- package/esm/utils/escape-html.d.ts +0 -58
- package/esm/utils/escape-html.d.ts.map +0 -1
- package/esm/utils/index.d.ts +0 -10
- package/esm/utils/index.d.ts.map +0 -1
- package/esm/utils/index.js +0 -40
- package/esm/utils/safe-stringify.d.ts +0 -30
- package/esm/utils/safe-stringify.d.ts.map +0 -1
- package/esm/validation/error-box.d.ts +0 -56
- package/esm/validation/error-box.d.ts.map +0 -1
- package/esm/validation/index.d.ts +0 -13
- package/esm/validation/index.d.ts.map +0 -1
- package/esm/validation/index.js +0 -562
- package/esm/validation/schema-paths.d.ts +0 -118
- package/esm/validation/schema-paths.d.ts.map +0 -1
- package/esm/validation/template-validator.d.ts +0 -143
- package/esm/validation/template-validator.d.ts.map +0 -1
- package/esm/validation/wrapper.d.ts +0 -97
- package/esm/validation/wrapper.d.ts.map +0 -1
- package/esm/web-components/core/attribute-parser.d.ts +0 -82
- package/esm/web-components/core/attribute-parser.d.ts.map +0 -1
- package/esm/web-components/core/base-element.d.ts +0 -197
- package/esm/web-components/core/base-element.d.ts.map +0 -1
- package/esm/web-components/core/index.d.ts +0 -9
- package/esm/web-components/core/index.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-alert.d.ts +0 -46
- package/esm/web-components/elements/fmcp-alert.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-badge.d.ts +0 -47
- package/esm/web-components/elements/fmcp-badge.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-button.d.ts +0 -117
- package/esm/web-components/elements/fmcp-button.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-card.d.ts +0 -53
- package/esm/web-components/elements/fmcp-card.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-input.d.ts +0 -96
- package/esm/web-components/elements/fmcp-input.d.ts.map +0 -1
- package/esm/web-components/elements/fmcp-select.d.ts +0 -100
- package/esm/web-components/elements/fmcp-select.d.ts.map +0 -1
- package/esm/web-components/elements/index.d.ts +0 -13
- package/esm/web-components/elements/index.d.ts.map +0 -1
- package/esm/web-components/index.d.ts +0 -50
- package/esm/web-components/index.d.ts.map +0 -1
- package/esm/web-components/register.d.ts +0 -57
- package/esm/web-components/register.d.ts.map +0 -1
- package/esm/web-components/types.d.ts +0 -122
- package/esm/web-components/types.d.ts.map +0 -1
- package/esm/widgets/index.d.ts +0 -8
- package/esm/widgets/index.d.ts.map +0 -1
- package/esm/widgets/index.js +0 -941
- package/esm/widgets/progress.d.ts +0 -133
- package/esm/widgets/progress.d.ts.map +0 -1
- package/esm/widgets/resource.d.ts +0 -163
- package/esm/widgets/resource.d.ts.map +0 -1
- package/handlebars/expression-extractor.d.ts +0 -147
- package/handlebars/expression-extractor.d.ts.map +0 -1
- package/handlebars/helpers.d.ts +0 -339
- package/handlebars/helpers.d.ts.map +0 -1
- package/handlebars/index.d.ts +0 -195
- package/handlebars/index.d.ts.map +0 -1
- package/handlebars/index.js +0 -666
- package/pages/consent.d.ts +0 -117
- package/pages/consent.d.ts.map +0 -1
- package/pages/error.d.ts +0 -101
- package/pages/error.d.ts.map +0 -1
- package/pages/index.d.ts +0 -9
- package/pages/index.d.ts.map +0 -1
- package/pages/index.js +0 -1602
- package/react/utils.d.ts +0 -43
- package/react/utils.d.ts.map +0 -1
- package/registry/index.d.ts +0 -46
- package/registry/index.d.ts.map +0 -1
- package/registry/index.js +0 -6465
- package/registry/render-template.d.ts +0 -91
- package/registry/render-template.d.ts.map +0 -1
- package/registry/tool-ui.registry.d.ts +0 -294
- package/registry/tool-ui.registry.d.ts.map +0 -1
- package/registry/uri-utils.d.ts +0 -56
- package/registry/uri-utils.d.ts.map +0 -1
- package/renderers/cache.d.ts +0 -145
- package/renderers/cache.d.ts.map +0 -1
- package/renderers/html.renderer.d.ts +0 -123
- package/renderers/html.renderer.d.ts.map +0 -1
- package/renderers/registry.d.ts +0 -134
- package/renderers/registry.d.ts.map +0 -1
- package/renderers/types.d.ts +0 -342
- package/renderers/types.d.ts.map +0 -1
- package/renderers/utils/detect.d.ts +0 -107
- package/renderers/utils/detect.d.ts.map +0 -1
- package/renderers/utils/hash.d.ts +0 -40
- package/renderers/utils/hash.d.ts.map +0 -1
- package/renderers/utils/index.d.ts +0 -9
- package/renderers/utils/index.d.ts.map +0 -1
- package/renderers/utils/transpiler.d.ts +0 -89
- package/renderers/utils/transpiler.d.ts.map +0 -1
- package/runtime/adapters/html.adapter.d.ts +0 -59
- package/runtime/adapters/html.adapter.d.ts.map +0 -1
- package/runtime/adapters/index.d.ts +0 -26
- package/runtime/adapters/index.d.ts.map +0 -1
- package/runtime/adapters/mdx.adapter.d.ts +0 -73
- package/runtime/adapters/mdx.adapter.d.ts.map +0 -1
- package/runtime/adapters/react.adapter.d.ts +0 -70
- package/runtime/adapters/react.adapter.d.ts.map +0 -1
- package/runtime/adapters/types.d.ts +0 -95
- package/runtime/adapters/types.d.ts.map +0 -1
- package/runtime/csp.d.ts +0 -48
- package/runtime/csp.d.ts.map +0 -1
- package/runtime/index.d.ts +0 -17
- package/runtime/index.d.ts.map +0 -1
- package/runtime/index.js +0 -5264
- package/runtime/mcp-bridge.d.ts +0 -101
- package/runtime/mcp-bridge.d.ts.map +0 -1
- package/runtime/renderer-runtime.d.ts +0 -133
- package/runtime/renderer-runtime.d.ts.map +0 -1
- package/runtime/sanitizer.d.ts +0 -172
- package/runtime/sanitizer.d.ts.map +0 -1
- package/runtime/types.d.ts +0 -415
- package/runtime/types.d.ts.map +0 -1
- package/runtime/wrapper.d.ts +0 -421
- package/runtime/wrapper.d.ts.map +0 -1
- package/styles/index.d.ts +0 -8
- package/styles/index.d.ts.map +0 -1
- package/styles/index.js +0 -222
- package/styles/variants.d.ts +0 -51
- package/styles/variants.d.ts.map +0 -1
- package/theme/cdn.d.ts +0 -195
- package/theme/cdn.d.ts.map +0 -1
- package/theme/index.d.ts +0 -18
- package/theme/index.d.ts.map +0 -1
- package/theme/index.js +0 -757
- package/theme/platforms.d.ts +0 -107
- package/theme/platforms.d.ts.map +0 -1
- package/theme/presets/github-openai.d.ts +0 -50
- package/theme/presets/github-openai.d.ts.map +0 -1
- package/theme/presets/index.d.ts +0 -11
- package/theme/presets/index.d.ts.map +0 -1
- package/theme/theme.d.ts +0 -396
- package/theme/theme.d.ts.map +0 -1
- package/tool-template/builder.d.ts +0 -213
- package/tool-template/builder.d.ts.map +0 -1
- package/tool-template/index.d.ts +0 -16
- package/tool-template/index.d.ts.map +0 -1
- package/tool-template/index.js +0 -3559
- package/types/index.d.ts +0 -14
- package/types/index.d.ts.map +0 -1
- package/types/index.js +0 -108
- package/types/ui-config.d.ts +0 -639
- package/types/ui-config.d.ts.map +0 -1
- package/types/ui-runtime.d.ts +0 -1007
- package/types/ui-runtime.d.ts.map +0 -1
- package/typings/cache/cache-adapter.d.ts +0 -125
- package/typings/cache/cache-adapter.d.ts.map +0 -1
- package/typings/cache/index.d.ts +0 -10
- package/typings/cache/index.d.ts.map +0 -1
- package/typings/cache/memory-cache.d.ts +0 -92
- package/typings/cache/memory-cache.d.ts.map +0 -1
- package/typings/dts-parser.d.ts +0 -90
- package/typings/dts-parser.d.ts.map +0 -1
- package/typings/index.d.ts +0 -48
- package/typings/index.d.ts.map +0 -1
- package/typings/schemas.d.ts +0 -232
- package/typings/schemas.d.ts.map +0 -1
- package/typings/type-fetcher.d.ts +0 -89
- package/typings/type-fetcher.d.ts.map +0 -1
- package/typings/types.d.ts +0 -320
- package/typings/types.d.ts.map +0 -1
- package/utils/escape-html.d.ts +0 -58
- package/utils/escape-html.d.ts.map +0 -1
- package/utils/index.d.ts +0 -10
- package/utils/index.d.ts.map +0 -1
- package/utils/index.js +0 -70
- package/utils/safe-stringify.d.ts +0 -30
- package/utils/safe-stringify.d.ts.map +0 -1
- package/validation/error-box.d.ts +0 -56
- package/validation/error-box.d.ts.map +0 -1
- package/validation/index.d.ts +0 -13
- package/validation/index.d.ts.map +0 -1
- package/validation/index.js +0 -603
- package/validation/schema-paths.d.ts +0 -118
- package/validation/schema-paths.d.ts.map +0 -1
- package/validation/template-validator.d.ts +0 -143
- package/validation/template-validator.d.ts.map +0 -1
- package/validation/wrapper.d.ts +0 -97
- package/validation/wrapper.d.ts.map +0 -1
- package/widgets/index.d.ts +0 -8
- package/widgets/index.d.ts.map +0 -1
- package/widgets/index.js +0 -978
- package/widgets/progress.d.ts +0 -133
- package/widgets/progress.d.ts.map +0 -1
- package/widgets/resource.d.ts +0 -163
- package/widgets/resource.d.ts.map +0 -1
- /package/esm/render/{index.js → index.mjs} +0 -0
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @file button.ts
|
|
3
|
-
* @description Button Component for FrontMCP UI.
|
|
4
|
-
*
|
|
5
|
-
* Versatile button component with multiple variants, sizes, and states.
|
|
6
|
-
*
|
|
7
|
-
* @example Basic button
|
|
8
|
-
* ```typescript
|
|
9
|
-
* import { button } from '@frontmcp/ui';
|
|
10
|
-
*
|
|
11
|
-
* // Primary button (default)
|
|
12
|
-
* const html = button('Click Me');
|
|
13
|
-
* // <button type="button" class="...bg-primary...">Click Me</button>
|
|
14
|
-
* ```
|
|
15
|
-
*
|
|
16
|
-
* @example Button variants
|
|
17
|
-
* ```typescript
|
|
18
|
-
* import { button, primaryButton, dangerButton, outlineButton } from '@frontmcp/ui';
|
|
19
|
-
*
|
|
20
|
-
* // Using variant option
|
|
21
|
-
* const secondary = button('Save', { variant: 'secondary' });
|
|
22
|
-
* const danger = button('Delete', { variant: 'danger' });
|
|
23
|
-
*
|
|
24
|
-
* // Using shorthand functions
|
|
25
|
-
* const primary = primaryButton('Submit');
|
|
26
|
-
* const outline = outlineButton('Cancel');
|
|
27
|
-
* ```
|
|
28
|
-
*
|
|
29
|
-
* @example Button with loading state
|
|
30
|
-
* ```typescript
|
|
31
|
-
* const loadingBtn = button('Saving...', {
|
|
32
|
-
* loading: true,
|
|
33
|
-
* disabled: true,
|
|
34
|
-
* });
|
|
35
|
-
* ```
|
|
36
|
-
*
|
|
37
|
-
* @example Button group
|
|
38
|
-
* ```typescript
|
|
39
|
-
* import { button, buttonGroup } from '@frontmcp/ui';
|
|
40
|
-
*
|
|
41
|
-
* const group = buttonGroup([
|
|
42
|
-
* button('Edit', { variant: 'outline' }),
|
|
43
|
-
* button('Delete', { variant: 'danger' }),
|
|
44
|
-
* ], { attached: true });
|
|
45
|
-
* ```
|
|
46
|
-
*
|
|
47
|
-
* @module @frontmcp/ui/components/button
|
|
48
|
-
*/
|
|
49
|
-
import { type ButtonOptions, type ButtonVariant, type ButtonSize, type ButtonGroupOptions } from './button.schema';
|
|
50
|
-
export type { ButtonOptions, ButtonVariant, ButtonSize, ButtonGroupOptions };
|
|
51
|
-
/**
|
|
52
|
-
* Build a button component
|
|
53
|
-
*
|
|
54
|
-
* @param text - Button label text (used as aria-label for icon-only buttons)
|
|
55
|
-
* @param options - Button configuration options
|
|
56
|
-
* @returns HTML string for the button, or validation error box on invalid input
|
|
57
|
-
*
|
|
58
|
-
* @remarks
|
|
59
|
-
* **Security considerations:**
|
|
60
|
-
* - The `iconBefore` and `iconAfter` options accept raw HTML strings for SVG icons.
|
|
61
|
-
* These are NOT escaped and should only contain trusted content (e.g., icon library output).
|
|
62
|
-
* Never pass user-provided content to these options.
|
|
63
|
-
* - The `href` option uses an allowlist for safe protocols. Only the following are allowed:
|
|
64
|
-
* - `http://`, `https://` - absolute URLs
|
|
65
|
-
* - `/` - absolute paths (e.g., "/login", "/api/users")
|
|
66
|
-
* - `#` - anchor links (e.g., "#section")
|
|
67
|
-
* - `mailto:` - email links
|
|
68
|
-
* - `tel:` - phone links
|
|
69
|
-
* Note: Bare relative URLs like "login" or "./foo" are NOT allowed and will fall back to
|
|
70
|
-
* button behavior. Use absolute paths ("/login") instead.
|
|
71
|
-
* - The `data` option keys are sanitized to prevent malformed attributes.
|
|
72
|
-
*
|
|
73
|
-
* **Accessibility:**
|
|
74
|
-
* - When `iconOnly: true`, the `text` parameter is automatically used as `aria-label`
|
|
75
|
-
* unless an explicit `ariaLabel` option is provided.
|
|
76
|
-
* - Empty button text with `iconOnly: false` will log a warning for accessibility.
|
|
77
|
-
* - Icon-only buttons without text or ariaLabel will log a warning.
|
|
78
|
-
*/
|
|
79
|
-
export declare function button(text: string, options?: ButtonOptions): string;
|
|
80
|
-
/**
|
|
81
|
-
* Build a button group
|
|
82
|
-
*
|
|
83
|
-
* @param buttons - Array of button HTML strings
|
|
84
|
-
* @param options - Button group configuration options
|
|
85
|
-
* @returns HTML string for the button group, or validation error box on invalid input
|
|
86
|
-
*/
|
|
87
|
-
export declare function buttonGroup(buttons: string[], options?: ButtonGroupOptions): string;
|
|
88
|
-
/** Primary button shorthand */
|
|
89
|
-
export declare const primaryButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
90
|
-
/** Secondary button shorthand */
|
|
91
|
-
export declare const secondaryButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
92
|
-
/** Outline button shorthand */
|
|
93
|
-
export declare const outlineButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
94
|
-
/** Ghost button shorthand */
|
|
95
|
-
export declare const ghostButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
96
|
-
/** Danger button shorthand */
|
|
97
|
-
export declare const dangerButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
98
|
-
/** Link button shorthand */
|
|
99
|
-
export declare const linkButton: (text: string, opts?: Omit<ButtonOptions, "variant">) => string;
|
|
100
|
-
//# sourceMappingURL=button.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../src/components/button.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AAIH,OAAO,EAGL,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,UAAU,EACf,KAAK,kBAAkB,EACxB,MAAM,iBAAiB,CAAC;AAGzB,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,UAAU,EAAE,kBAAkB,EAAE,CAAC;AAyF7E;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,GAAE,aAAkB,GAAG,MAAM,CAkHxE;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,GAAE,kBAAuB,GAAG,MAAM,CAkCvF;AAMD,+BAA+B;AAC/B,eAAO,MAAM,aAAa,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC;AAEhD,iCAAiC;AACjC,eAAO,MAAM,eAAe,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC;AAElD,+BAA+B;AAC/B,eAAO,MAAM,aAAa,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC;AAEhD,6BAA6B;AAC7B,eAAO,MAAM,WAAW,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC;AAE9C,8BAA8B;AAC9B,eAAO,MAAM,YAAY,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC;AAE/C,4BAA4B;AAC5B,eAAO,MAAM,UAAU,GAAI,MAAM,MAAM,EAAE,OAAO,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,WAClC,CAAC"}
|
|
@@ -1,120 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @file button.schema.ts
|
|
3
|
-
* @description Zod schemas for Button component options validation.
|
|
4
|
-
*
|
|
5
|
-
* Provides strict validation schemas for button options including variants,
|
|
6
|
-
* sizes, and data attributes. All schemas use .strict()
|
|
7
|
-
* to reject unknown properties.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```typescript
|
|
11
|
-
* import { ButtonOptionsSchema } from '@frontmcp/ui';
|
|
12
|
-
*
|
|
13
|
-
* // Validate button options
|
|
14
|
-
* const result = ButtonOptionsSchema.safeParse({ variant: 'primary' });
|
|
15
|
-
* if (result.success) {
|
|
16
|
-
* // Use result.data
|
|
17
|
-
* }
|
|
18
|
-
* ```
|
|
19
|
-
*
|
|
20
|
-
* @module @frontmcp/ui/components/button.schema
|
|
21
|
-
*/
|
|
22
|
-
import { z } from 'zod';
|
|
23
|
-
/**
|
|
24
|
-
* Button variant enum schema
|
|
25
|
-
*/
|
|
26
|
-
export declare const ButtonVariantSchema: z.ZodEnum<{
|
|
27
|
-
primary: "primary";
|
|
28
|
-
secondary: "secondary";
|
|
29
|
-
link: "link";
|
|
30
|
-
success: "success";
|
|
31
|
-
danger: "danger";
|
|
32
|
-
outline: "outline";
|
|
33
|
-
ghost: "ghost";
|
|
34
|
-
}>;
|
|
35
|
-
/**
|
|
36
|
-
* Button variant type
|
|
37
|
-
*/
|
|
38
|
-
export type ButtonVariant = z.infer<typeof ButtonVariantSchema>;
|
|
39
|
-
/**
|
|
40
|
-
* Button size enum schema
|
|
41
|
-
*/
|
|
42
|
-
export declare const ButtonSizeSchema: z.ZodEnum<{
|
|
43
|
-
xs: "xs";
|
|
44
|
-
sm: "sm";
|
|
45
|
-
lg: "lg";
|
|
46
|
-
xl: "xl";
|
|
47
|
-
md: "md";
|
|
48
|
-
}>;
|
|
49
|
-
/**
|
|
50
|
-
* Button size type
|
|
51
|
-
*/
|
|
52
|
-
export type ButtonSize = z.infer<typeof ButtonSizeSchema>;
|
|
53
|
-
/**
|
|
54
|
-
* Complete button options schema
|
|
55
|
-
*/
|
|
56
|
-
export declare const ButtonOptionsSchema: z.ZodObject<{
|
|
57
|
-
variant: z.ZodOptional<z.ZodEnum<{
|
|
58
|
-
primary: "primary";
|
|
59
|
-
secondary: "secondary";
|
|
60
|
-
link: "link";
|
|
61
|
-
success: "success";
|
|
62
|
-
danger: "danger";
|
|
63
|
-
outline: "outline";
|
|
64
|
-
ghost: "ghost";
|
|
65
|
-
}>>;
|
|
66
|
-
size: z.ZodOptional<z.ZodEnum<{
|
|
67
|
-
xs: "xs";
|
|
68
|
-
sm: "sm";
|
|
69
|
-
lg: "lg";
|
|
70
|
-
xl: "xl";
|
|
71
|
-
md: "md";
|
|
72
|
-
}>>;
|
|
73
|
-
type: z.ZodOptional<z.ZodEnum<{
|
|
74
|
-
button: "button";
|
|
75
|
-
submit: "submit";
|
|
76
|
-
reset: "reset";
|
|
77
|
-
}>>;
|
|
78
|
-
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
79
|
-
loading: z.ZodOptional<z.ZodBoolean>;
|
|
80
|
-
fullWidth: z.ZodOptional<z.ZodBoolean>;
|
|
81
|
-
iconBefore: z.ZodOptional<z.ZodString>;
|
|
82
|
-
iconAfter: z.ZodOptional<z.ZodString>;
|
|
83
|
-
iconOnly: z.ZodOptional<z.ZodBoolean>;
|
|
84
|
-
className: z.ZodOptional<z.ZodString>;
|
|
85
|
-
id: z.ZodOptional<z.ZodString>;
|
|
86
|
-
name: z.ZodOptional<z.ZodString>;
|
|
87
|
-
value: z.ZodOptional<z.ZodString>;
|
|
88
|
-
href: z.ZodOptional<z.ZodString>;
|
|
89
|
-
target: z.ZodOptional<z.ZodEnum<{
|
|
90
|
-
_blank: "_blank";
|
|
91
|
-
_self: "_self";
|
|
92
|
-
}>>;
|
|
93
|
-
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
94
|
-
ariaLabel: z.ZodOptional<z.ZodString>;
|
|
95
|
-
}, z.core.$strict>;
|
|
96
|
-
/**
|
|
97
|
-
* Button options type (derived from schema)
|
|
98
|
-
*/
|
|
99
|
-
export type ButtonOptions = z.infer<typeof ButtonOptionsSchema>;
|
|
100
|
-
/**
|
|
101
|
-
* Button group options schema
|
|
102
|
-
*/
|
|
103
|
-
export declare const ButtonGroupOptionsSchema: z.ZodObject<{
|
|
104
|
-
attached: z.ZodOptional<z.ZodBoolean>;
|
|
105
|
-
direction: z.ZodOptional<z.ZodEnum<{
|
|
106
|
-
horizontal: "horizontal";
|
|
107
|
-
vertical: "vertical";
|
|
108
|
-
}>>;
|
|
109
|
-
gap: z.ZodOptional<z.ZodEnum<{
|
|
110
|
-
sm: "sm";
|
|
111
|
-
lg: "lg";
|
|
112
|
-
md: "md";
|
|
113
|
-
}>>;
|
|
114
|
-
className: z.ZodOptional<z.ZodString>;
|
|
115
|
-
}, z.core.$strict>;
|
|
116
|
-
/**
|
|
117
|
-
* Button group options type
|
|
118
|
-
*/
|
|
119
|
-
export type ButtonGroupOptions = z.infer<typeof ButtonGroupOptionsSchema>;
|
|
120
|
-
//# sourceMappingURL=button.schema.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"button.schema.d.ts","sourceRoot":"","sources":["../../../src/components/button.schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;EAAoF,CAAC;AAErH;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,gBAAgB;;;;;;EAAyC,CAAC;AAEvE;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAM1D;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAqCrB,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAMhE;;GAEG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;kBAW1B,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
|
package/esm/components/card.d.ts
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Card Component
|
|
3
|
-
*
|
|
4
|
-
* Versatile card component for content containers.
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* Card variant styles
|
|
8
|
-
*/
|
|
9
|
-
export type CardVariant = 'default' | 'outlined' | 'elevated' | 'filled' | 'ghost';
|
|
10
|
-
/**
|
|
11
|
-
* Card size options
|
|
12
|
-
*/
|
|
13
|
-
export type CardSize = 'sm' | 'md' | 'lg';
|
|
14
|
-
/**
|
|
15
|
-
* Card component options
|
|
16
|
-
*/
|
|
17
|
-
export interface CardOptions {
|
|
18
|
-
/** Card variant */
|
|
19
|
-
variant?: CardVariant;
|
|
20
|
-
/** Card size (padding) */
|
|
21
|
-
size?: CardSize;
|
|
22
|
-
/** Card title */
|
|
23
|
-
title?: string;
|
|
24
|
-
/** Card subtitle/description */
|
|
25
|
-
subtitle?: string;
|
|
26
|
-
/** Header actions (HTML) */
|
|
27
|
-
headerActions?: string;
|
|
28
|
-
/** Footer content (HTML) */
|
|
29
|
-
footer?: string;
|
|
30
|
-
/** Additional CSS classes */
|
|
31
|
-
className?: string;
|
|
32
|
-
/** Card ID */
|
|
33
|
-
id?: string;
|
|
34
|
-
/** Data attributes */
|
|
35
|
-
data?: Record<string, string>;
|
|
36
|
-
/** Clickable card (adds hover effects) */
|
|
37
|
-
clickable?: boolean;
|
|
38
|
-
/** Click handler URL */
|
|
39
|
-
href?: string;
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* Build a card component
|
|
43
|
-
*/
|
|
44
|
-
export declare function card(content: string, options?: CardOptions): string;
|
|
45
|
-
/**
|
|
46
|
-
* Build a card group (horizontal or vertical)
|
|
47
|
-
*/
|
|
48
|
-
export declare function cardGroup(cards: string[], options?: {
|
|
49
|
-
direction?: 'horizontal' | 'vertical';
|
|
50
|
-
gap?: 'sm' | 'md' | 'lg';
|
|
51
|
-
className?: string;
|
|
52
|
-
}): string;
|
|
53
|
-
//# sourceMappingURL=card.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"card.d.ts","sourceRoot":"","sources":["../../../src/components/card.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEnF;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAE1C;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,mBAAmB;IACnB,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,0BAA0B;IAC1B,IAAI,CAAC,EAAE,QAAQ,CAAC;IAChB,iBAAiB;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gCAAgC;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,4BAA4B;IAC5B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,4BAA4B;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,6BAA6B;IAC7B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,sBAAsB;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,wBAAwB;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AA0CD;;GAEG;AACH,wBAAgB,IAAI,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,GAAE,WAAgB,GAAG,MAAM,CAoDvE;AAED;;GAEG;AACH,wBAAgB,SAAS,CACvB,KAAK,EAAE,MAAM,EAAE,EACf,OAAO,GAAE;IACP,SAAS,CAAC,EAAE,YAAY,GAAG,UAAU,CAAC;IACtC,GAAG,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;CACf,GACL,MAAM,CASR"}
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @file card.schema.ts
|
|
3
|
-
* @description Zod schemas for Card component options validation.
|
|
4
|
-
*
|
|
5
|
-
* Provides strict validation schemas for card options including variants,
|
|
6
|
-
* sizes, and clickable behavior.
|
|
7
|
-
*
|
|
8
|
-
* @example
|
|
9
|
-
* ```typescript
|
|
10
|
-
* import { CardOptionsSchema } from '@frontmcp/ui';
|
|
11
|
-
*
|
|
12
|
-
* const result = CardOptionsSchema.safeParse({ variant: 'elevated' });
|
|
13
|
-
* ```
|
|
14
|
-
*
|
|
15
|
-
* @module @frontmcp/ui/components/card.schema
|
|
16
|
-
*/
|
|
17
|
-
import { z } from 'zod';
|
|
18
|
-
/**
|
|
19
|
-
* Card variant enum schema
|
|
20
|
-
*/
|
|
21
|
-
export declare const CardVariantSchema: z.ZodEnum<{
|
|
22
|
-
default: "default";
|
|
23
|
-
elevated: "elevated";
|
|
24
|
-
ghost: "ghost";
|
|
25
|
-
outlined: "outlined";
|
|
26
|
-
filled: "filled";
|
|
27
|
-
}>;
|
|
28
|
-
/**
|
|
29
|
-
* Card variant type
|
|
30
|
-
*/
|
|
31
|
-
export type CardVariant = z.infer<typeof CardVariantSchema>;
|
|
32
|
-
/**
|
|
33
|
-
* Card size enum schema
|
|
34
|
-
*/
|
|
35
|
-
export declare const CardSizeSchema: z.ZodEnum<{
|
|
36
|
-
sm: "sm";
|
|
37
|
-
lg: "lg";
|
|
38
|
-
md: "md";
|
|
39
|
-
}>;
|
|
40
|
-
/**
|
|
41
|
-
* Card size type
|
|
42
|
-
*/
|
|
43
|
-
export type CardSize = z.infer<typeof CardSizeSchema>;
|
|
44
|
-
/**
|
|
45
|
-
* Complete card options schema
|
|
46
|
-
*/
|
|
47
|
-
export declare const CardOptionsSchema: z.ZodObject<{
|
|
48
|
-
variant: z.ZodOptional<z.ZodEnum<{
|
|
49
|
-
default: "default";
|
|
50
|
-
elevated: "elevated";
|
|
51
|
-
ghost: "ghost";
|
|
52
|
-
outlined: "outlined";
|
|
53
|
-
filled: "filled";
|
|
54
|
-
}>>;
|
|
55
|
-
size: z.ZodOptional<z.ZodEnum<{
|
|
56
|
-
sm: "sm";
|
|
57
|
-
lg: "lg";
|
|
58
|
-
md: "md";
|
|
59
|
-
}>>;
|
|
60
|
-
title: z.ZodOptional<z.ZodString>;
|
|
61
|
-
subtitle: z.ZodOptional<z.ZodString>;
|
|
62
|
-
headerActions: z.ZodOptional<z.ZodString>;
|
|
63
|
-
footer: z.ZodOptional<z.ZodString>;
|
|
64
|
-
className: z.ZodOptional<z.ZodString>;
|
|
65
|
-
id: z.ZodOptional<z.ZodString>;
|
|
66
|
-
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
67
|
-
clickable: z.ZodOptional<z.ZodBoolean>;
|
|
68
|
-
href: z.ZodOptional<z.ZodString>;
|
|
69
|
-
}, z.core.$strict>;
|
|
70
|
-
/**
|
|
71
|
-
* Card options type (derived from schema)
|
|
72
|
-
*/
|
|
73
|
-
export type CardOptions = z.infer<typeof CardOptionsSchema>;
|
|
74
|
-
/**
|
|
75
|
-
* Card group options schema
|
|
76
|
-
*/
|
|
77
|
-
export declare const CardGroupOptionsSchema: z.ZodObject<{
|
|
78
|
-
direction: z.ZodOptional<z.ZodEnum<{
|
|
79
|
-
horizontal: "horizontal";
|
|
80
|
-
vertical: "vertical";
|
|
81
|
-
}>>;
|
|
82
|
-
gap: z.ZodOptional<z.ZodEnum<{
|
|
83
|
-
sm: "sm";
|
|
84
|
-
lg: "lg";
|
|
85
|
-
md: "md";
|
|
86
|
-
}>>;
|
|
87
|
-
className: z.ZodOptional<z.ZodString>;
|
|
88
|
-
}, z.core.$strict>;
|
|
89
|
-
/**
|
|
90
|
-
* Card group options type
|
|
91
|
-
*/
|
|
92
|
-
export type CardGroupOptions = z.infer<typeof CardGroupOptionsSchema>;
|
|
93
|
-
//# sourceMappingURL=card.schema.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"card.schema.d.ts","sourceRoot":"","sources":["../../../src/components/card.schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;EAAiE,CAAC;AAEhG;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE5D;;GAEG;AACH,eAAO,MAAM,cAAc;;;;EAA6B,CAAC;AAEzD;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAMtD;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;kBAyBnB,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAM5D;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;kBASxB,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC"}
|
package/esm/components/form.d.ts
DELETED
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Form Components
|
|
3
|
-
*
|
|
4
|
-
* Form elements including inputs, selects, textareas, and form layouts.
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* Input type options
|
|
8
|
-
*/
|
|
9
|
-
export type InputType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'search' | 'date' | 'time' | 'datetime-local' | 'hidden';
|
|
10
|
-
/**
|
|
11
|
-
* Input size options
|
|
12
|
-
*/
|
|
13
|
-
export type InputSize = 'sm' | 'md' | 'lg';
|
|
14
|
-
/**
|
|
15
|
-
* Input state
|
|
16
|
-
*/
|
|
17
|
-
export type InputState = 'default' | 'error' | 'success' | 'warning';
|
|
18
|
-
/**
|
|
19
|
-
* Base input options
|
|
20
|
-
*/
|
|
21
|
-
export interface InputOptions {
|
|
22
|
-
/** Input type */
|
|
23
|
-
type?: InputType;
|
|
24
|
-
/** Input name */
|
|
25
|
-
name: string;
|
|
26
|
-
/** Input ID (defaults to name) */
|
|
27
|
-
id?: string;
|
|
28
|
-
/** Input value */
|
|
29
|
-
value?: string;
|
|
30
|
-
/** Placeholder text */
|
|
31
|
-
placeholder?: string;
|
|
32
|
-
/** Label text */
|
|
33
|
-
label?: string;
|
|
34
|
-
/** Helper text */
|
|
35
|
-
helper?: string;
|
|
36
|
-
/** Error message */
|
|
37
|
-
error?: string;
|
|
38
|
-
/** Input size */
|
|
39
|
-
size?: InputSize;
|
|
40
|
-
/** Input state */
|
|
41
|
-
state?: InputState;
|
|
42
|
-
/** Required field */
|
|
43
|
-
required?: boolean;
|
|
44
|
-
/** Disabled state */
|
|
45
|
-
disabled?: boolean;
|
|
46
|
-
/** Readonly state */
|
|
47
|
-
readonly?: boolean;
|
|
48
|
-
/** Autocomplete attribute */
|
|
49
|
-
autocomplete?: string;
|
|
50
|
-
/** Pattern for validation */
|
|
51
|
-
pattern?: string;
|
|
52
|
-
/** Min value (for number/date) */
|
|
53
|
-
min?: string | number;
|
|
54
|
-
/** Max value (for number/date) */
|
|
55
|
-
max?: string | number;
|
|
56
|
-
/** Step value (for number) */
|
|
57
|
-
step?: string | number;
|
|
58
|
-
/** Additional CSS classes */
|
|
59
|
-
className?: string;
|
|
60
|
-
/** Data attributes */
|
|
61
|
-
data?: Record<string, string>;
|
|
62
|
-
/** Icon before input */
|
|
63
|
-
iconBefore?: string;
|
|
64
|
-
/** Icon after input */
|
|
65
|
-
iconAfter?: string;
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* Select options
|
|
69
|
-
*/
|
|
70
|
-
export interface SelectOption {
|
|
71
|
-
value: string;
|
|
72
|
-
label: string;
|
|
73
|
-
disabled?: boolean;
|
|
74
|
-
selected?: boolean;
|
|
75
|
-
}
|
|
76
|
-
export interface SelectOptions extends Omit<InputOptions, 'type' | 'pattern' | 'min' | 'max' | 'step' | 'autocomplete'> {
|
|
77
|
-
/** Select options */
|
|
78
|
-
options: SelectOption[];
|
|
79
|
-
/** Multiple selection */
|
|
80
|
-
multiple?: boolean;
|
|
81
|
-
}
|
|
82
|
-
/**
|
|
83
|
-
* Textarea options
|
|
84
|
-
*/
|
|
85
|
-
export interface TextareaOptions extends Omit<InputOptions, 'type' | 'pattern' | 'min' | 'max' | 'step'> {
|
|
86
|
-
/** Number of rows */
|
|
87
|
-
rows?: number;
|
|
88
|
-
/** Resize behavior */
|
|
89
|
-
resize?: 'none' | 'vertical' | 'horizontal' | 'both';
|
|
90
|
-
}
|
|
91
|
-
/**
|
|
92
|
-
* Checkbox options
|
|
93
|
-
*/
|
|
94
|
-
export interface CheckboxOptions {
|
|
95
|
-
/** Input name */
|
|
96
|
-
name: string;
|
|
97
|
-
/** Input ID */
|
|
98
|
-
id?: string;
|
|
99
|
-
/** Input value */
|
|
100
|
-
value?: string;
|
|
101
|
-
/** Label text */
|
|
102
|
-
label: string;
|
|
103
|
-
/** Checked state */
|
|
104
|
-
checked?: boolean;
|
|
105
|
-
/** Disabled state */
|
|
106
|
-
disabled?: boolean;
|
|
107
|
-
/** Helper text */
|
|
108
|
-
helper?: string;
|
|
109
|
-
/** Error message */
|
|
110
|
-
error?: string;
|
|
111
|
-
/** Additional CSS classes */
|
|
112
|
-
className?: string;
|
|
113
|
-
}
|
|
114
|
-
/**
|
|
115
|
-
* Radio group options
|
|
116
|
-
*/
|
|
117
|
-
export interface RadioGroupOptions {
|
|
118
|
-
/** Group name */
|
|
119
|
-
name: string;
|
|
120
|
-
/** Radio options */
|
|
121
|
-
options: Array<{
|
|
122
|
-
value: string;
|
|
123
|
-
label: string;
|
|
124
|
-
disabled?: boolean;
|
|
125
|
-
}>;
|
|
126
|
-
/** Selected value */
|
|
127
|
-
value?: string;
|
|
128
|
-
/** Label for the group */
|
|
129
|
-
label?: string;
|
|
130
|
-
/** Helper text */
|
|
131
|
-
helper?: string;
|
|
132
|
-
/** Error message */
|
|
133
|
-
error?: string;
|
|
134
|
-
/** Layout direction */
|
|
135
|
-
direction?: 'horizontal' | 'vertical';
|
|
136
|
-
/** Additional CSS classes */
|
|
137
|
-
className?: string;
|
|
138
|
-
}
|
|
139
|
-
/**
|
|
140
|
-
* Build a text input component
|
|
141
|
-
*/
|
|
142
|
-
export declare function input(options: InputOptions): string;
|
|
143
|
-
/**
|
|
144
|
-
* Build a select component
|
|
145
|
-
*/
|
|
146
|
-
export declare function select(options: SelectOptions): string;
|
|
147
|
-
/**
|
|
148
|
-
* Build a textarea component
|
|
149
|
-
*/
|
|
150
|
-
export declare function textarea(options: TextareaOptions): string;
|
|
151
|
-
/**
|
|
152
|
-
* Build a checkbox component
|
|
153
|
-
*/
|
|
154
|
-
export declare function checkbox(options: CheckboxOptions): string;
|
|
155
|
-
/**
|
|
156
|
-
* Build a radio group component
|
|
157
|
-
*/
|
|
158
|
-
export declare function radioGroup(options: RadioGroupOptions): string;
|
|
159
|
-
/**
|
|
160
|
-
* Form wrapper options
|
|
161
|
-
*/
|
|
162
|
-
export interface FormOptions {
|
|
163
|
-
/** Form action URL */
|
|
164
|
-
action?: string;
|
|
165
|
-
/** HTTP method */
|
|
166
|
-
method?: 'get' | 'post';
|
|
167
|
-
/** Form ID */
|
|
168
|
-
id?: string;
|
|
169
|
-
/** Additional CSS classes */
|
|
170
|
-
className?: string;
|
|
171
|
-
/** Prevent default submission */
|
|
172
|
-
preventDefault?: boolean;
|
|
173
|
-
/** Autocomplete */
|
|
174
|
-
autocomplete?: 'on' | 'off';
|
|
175
|
-
/** Enctype for file uploads */
|
|
176
|
-
enctype?: 'application/x-www-form-urlencoded' | 'multipart/form-data' | 'text/plain';
|
|
177
|
-
}
|
|
178
|
-
/**
|
|
179
|
-
* Build form wrapper
|
|
180
|
-
*/
|
|
181
|
-
export declare function form(content: string, options?: FormOptions): string;
|
|
182
|
-
/**
|
|
183
|
-
* Build form row (for horizontal forms)
|
|
184
|
-
*/
|
|
185
|
-
export declare function formRow(fields: string[], options?: {
|
|
186
|
-
gap?: 'sm' | 'md' | 'lg';
|
|
187
|
-
className?: string;
|
|
188
|
-
}): string;
|
|
189
|
-
/**
|
|
190
|
-
* Build form section with title
|
|
191
|
-
*/
|
|
192
|
-
export declare function formSection(content: string, options?: {
|
|
193
|
-
title?: string;
|
|
194
|
-
description?: string;
|
|
195
|
-
className?: string;
|
|
196
|
-
}): string;
|
|
197
|
-
/**
|
|
198
|
-
* Build form actions (submit/cancel buttons area)
|
|
199
|
-
*/
|
|
200
|
-
export declare function formActions(buttons: string[], options?: {
|
|
201
|
-
align?: 'left' | 'center' | 'right' | 'between';
|
|
202
|
-
className?: string;
|
|
203
|
-
}): string;
|
|
204
|
-
/**
|
|
205
|
-
* Build a hidden input
|
|
206
|
-
*/
|
|
207
|
-
export declare function hiddenInput(name: string, value: string): string;
|
|
208
|
-
/**
|
|
209
|
-
* Build CSRF token hidden input
|
|
210
|
-
*/
|
|
211
|
-
export declare function csrfInput(token: string): string;
|
|
212
|
-
//# sourceMappingURL=form.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"form.d.ts","sourceRoot":"","sources":["../../../src/components/form.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH;;GAEG;AACH,MAAM,MAAM,SAAS,GACjB,MAAM,GACN,OAAO,GACP,UAAU,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