@baishuyun/chat-sdk 0.1.9 → 1.0.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/.turbo/turbo-build.log +8 -107
- package/CHANGELOG.md +12 -0
- package/dist/chat-sdk.js +14087 -13890
- package/dist/chat-sdk.js.map +1 -1
- package/dist/chat-sdk.umd.cjs +150 -150
- package/dist/chat-sdk.umd.cjs.map +1 -1
- package/dist/index.css +1 -1
- package/dist/src/chat.d.ts +5 -0
- package/dist/src/chat.d.ts.map +1 -0
- package/dist/src/components/biz-comp/FakeBotMsg.d.ts +8 -0
- package/dist/src/components/biz-comp/FakeBotMsg.d.ts.map +1 -0
- package/dist/src/components/biz-comp/FieldChecker.d.ts +19 -0
- package/dist/src/components/biz-comp/FieldChecker.d.ts.map +1 -0
- package/dist/src/components/biz-comp/FieldCheckerListMsg.d.ts +19 -0
- package/dist/src/components/biz-comp/FieldCheckerListMsg.d.ts.map +1 -0
- package/dist/src/components/biz-comp/FieldValueChecker.d.ts +16 -0
- package/dist/src/components/biz-comp/FieldValueChecker.d.ts.map +1 -0
- package/dist/src/components/biz-comp/SubformFieldsValueChecker.d.ts +22 -0
- package/dist/src/components/biz-comp/SubformFieldsValueChecker.d.ts.map +1 -0
- package/dist/src/components/biz-comp/chat-client.d.ts +13 -0
- package/dist/src/components/biz-comp/chat-client.d.ts.map +1 -0
- package/dist/src/components/biz-comp/chat-frame.d.ts +6 -0
- package/dist/src/components/biz-comp/chat-frame.d.ts.map +1 -0
- package/dist/src/components/biz-comp/conversation.d.ts +10 -0
- package/dist/src/components/biz-comp/conversation.d.ts.map +1 -0
- package/dist/src/components/biz-comp/dash-widget-icon.d.ts +7 -0
- package/dist/src/components/biz-comp/dash-widget-icon.d.ts.map +1 -0
- package/dist/src/components/biz-comp/dock-btn.d.ts +2 -0
- package/dist/src/components/biz-comp/dock-btn.d.ts.map +1 -0
- package/dist/src/components/biz-comp/error-boundary.d.ts +15 -0
- package/dist/src/components/biz-comp/error-boundary.d.ts.map +1 -0
- package/dist/src/components/biz-comp/error-msg.d.ts +4 -0
- package/dist/src/components/biz-comp/error-msg.d.ts.map +1 -0
- package/dist/src/components/biz-comp/field-icon.d.ts +5 -0
- package/dist/src/components/biz-comp/field-icon.d.ts.map +1 -0
- package/dist/src/components/biz-comp/highlight-msg.d.ts +4 -0
- package/dist/src/components/biz-comp/highlight-msg.d.ts.map +1 -0
- package/dist/src/components/biz-comp/markdown-part.d.ts +7 -0
- package/dist/src/components/biz-comp/markdown-part.d.ts.map +1 -0
- package/dist/src/components/biz-comp/markdown.d.ts +5 -0
- package/dist/src/components/biz-comp/markdown.d.ts.map +1 -0
- package/dist/src/components/biz-comp/message-content.d.ts +6 -0
- package/dist/src/components/biz-comp/message-content.d.ts.map +1 -0
- package/dist/src/components/biz-comp/messages.d.ts +3 -0
- package/dist/src/components/biz-comp/messages.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/attachment-btn.d.ts +9 -0
- package/dist/src/components/biz-comp/multi-modal-input/attachment-btn.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/clear-btn.d.ts +8 -0
- package/dist/src/components/biz-comp/multi-modal-input/clear-btn.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/index.d.ts +22 -0
- package/dist/src/components/biz-comp/multi-modal-input/index.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/preview-attachment.d.ts +12 -0
- package/dist/src/components/biz-comp/multi-modal-input/preview-attachment.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/prompt-input.d.ts +36 -0
- package/dist/src/components/biz-comp/multi-modal-input/prompt-input.d.ts.map +1 -0
- package/dist/src/components/biz-comp/multi-modal-input/voice-btn.d.ts +9 -0
- package/dist/src/components/biz-comp/multi-modal-input/voice-btn.d.ts.map +1 -0
- package/dist/src/components/biz-comp/opening-lines.d.ts +3 -0
- package/dist/src/components/biz-comp/opening-lines.d.ts.map +1 -0
- package/dist/src/components/biz-comp/preview-message-wrapper.d.ts +12 -0
- package/dist/src/components/biz-comp/preview-message-wrapper.d.ts.map +1 -0
- package/dist/src/components/biz-comp/preview-message.d.ts +13 -0
- package/dist/src/components/biz-comp/preview-message.d.ts.map +1 -0
- package/dist/src/components/biz-comp/response.d.ts +6 -0
- package/dist/src/components/biz-comp/response.d.ts.map +1 -0
- package/dist/src/components/biz-comp/suggestions.d.ts +8 -0
- package/dist/src/components/biz-comp/suggestions.d.ts.map +1 -0
- package/dist/src/components/ui/badge.d.ts +10 -0
- package/dist/src/components/ui/badge.d.ts.map +1 -0
- package/dist/src/components/ui/button.d.ts +12 -0
- package/dist/src/components/ui/button.d.ts.map +1 -0
- package/dist/src/components/ui/card.d.ts +9 -0
- package/dist/src/components/ui/card.d.ts.map +1 -0
- package/dist/src/components/ui/checkbox.d.ts +5 -0
- package/dist/src/components/ui/checkbox.d.ts.map +1 -0
- package/dist/src/components/ui/collapsible.d.ts +6 -0
- package/dist/src/components/ui/collapsible.d.ts.map +1 -0
- package/dist/src/components/ui/dialog.d.ts +24 -0
- package/dist/src/components/ui/dialog.d.ts.map +1 -0
- package/dist/src/components/ui/dropdown-menu.d.ts +28 -0
- package/dist/src/components/ui/dropdown-menu.d.ts.map +1 -0
- package/dist/src/components/ui/icons.d.ts +176 -0
- package/dist/src/components/ui/icons.d.ts.map +1 -0
- package/dist/src/components/ui/input-group.d.ts +17 -0
- package/dist/src/components/ui/input-group.d.ts.map +1 -0
- package/dist/src/components/ui/input.d.ts +4 -0
- package/dist/src/components/ui/input.d.ts.map +1 -0
- package/dist/src/components/ui/label.d.ts +6 -0
- package/dist/src/components/ui/label.d.ts.map +1 -0
- package/dist/src/components/ui/one-time-click-btn.d.ts +4 -0
- package/dist/src/components/ui/one-time-click-btn.d.ts.map +1 -0
- package/dist/src/components/ui/select.d.ts +14 -0
- package/dist/src/components/ui/select.d.ts.map +1 -0
- package/dist/src/components/ui/spinner.d.ts +3 -0
- package/dist/src/components/ui/spinner.d.ts.map +1 -0
- package/dist/src/components/ui/tabs.d.ts +8 -0
- package/dist/src/components/ui/tabs.d.ts.map +1 -0
- package/dist/src/components/ui/textarea.d.ts +4 -0
- package/dist/src/components/ui/textarea.d.ts.map +1 -0
- package/dist/src/components/ui/tooltip.d.ts +13 -0
- package/dist/src/components/ui/tooltip.d.ts.map +1 -0
- package/dist/src/components/web-comp/fields-previewer-web-component.d.ts +60 -0
- package/dist/src/components/web-comp/fields-previewer-web-component.d.ts.map +1 -0
- package/dist/src/const/index.d.ts +5 -0
- package/dist/src/const/index.d.ts.map +1 -0
- package/dist/src/const/ui.d.ts +7 -0
- package/dist/src/const/ui.d.ts.map +1 -0
- package/dist/src/hooks/use-chat-preference.d.ts +3 -0
- package/dist/src/hooks/use-chat-preference.d.ts.map +1 -0
- package/dist/src/hooks/use-draggable.d.ts +24 -0
- package/dist/src/hooks/use-draggable.d.ts.map +1 -0
- package/dist/src/hooks/use-evt-bus.d.ts +2 -0
- package/dist/src/hooks/use-evt-bus.d.ts.map +1 -0
- package/dist/src/hooks/use-evt.d.ts +3 -0
- package/dist/src/hooks/use-evt.d.ts.map +1 -0
- package/dist/src/hooks/use-frame-mode.d.ts +20 -0
- package/dist/src/hooks/use-frame-mode.d.ts.map +1 -0
- package/dist/src/hooks/use-merged-chat.d.ts +7 -0
- package/dist/src/hooks/use-merged-chat.d.ts.map +1 -0
- package/dist/src/hooks/use-msg-status-broadcast.d.ts +3 -0
- package/dist/src/hooks/use-msg-status-broadcast.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin-component.d.ts +5 -0
- package/dist/src/hooks/use-plugin-component.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin-ctx.d.ts +3 -0
- package/dist/src/hooks/use-plugin-ctx.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin-custom-components.d.ts +5 -0
- package/dist/src/hooks/use-plugin-custom-components.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin-life-cycle-chain-runner.d.ts +5 -0
- package/dist/src/hooks/use-plugin-life-cycle-chain-runner.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin-list.d.ts +2 -0
- package/dist/src/hooks/use-plugin-list.d.ts.map +1 -0
- package/dist/src/hooks/use-plugin.d.ts +2 -0
- package/dist/src/hooks/use-plugin.d.ts.map +1 -0
- package/dist/src/hooks/use-scroll-to-bottom.d.ts +9 -0
- package/dist/src/hooks/use-scroll-to-bottom.d.ts.map +1 -0
- package/dist/src/hooks/use-shadow.d.ts +25 -0
- package/dist/src/hooks/use-shadow.d.ts.map +1 -0
- package/dist/src/hooks/use-streaming-anchor.d.ts +11 -0
- package/dist/src/hooks/use-streaming-anchor.d.ts.map +1 -0
- package/dist/src/hooks/use-toast.d.ts +3 -0
- package/dist/src/hooks/use-toast.d.ts.map +1 -0
- package/dist/src/hooks/use-voice-input.d.ts +31 -0
- package/dist/src/hooks/use-voice-input.d.ts.map +1 -0
- package/dist/src/index.d.ts +6 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/lib/clone.d.ts +32 -0
- package/dist/src/lib/clone.d.ts.map +1 -0
- package/dist/src/lib/event-emitter.d.ts +39 -0
- package/dist/src/lib/event-emitter.d.ts.map +1 -0
- package/dist/src/lib/parse-design-doc.d.ts +16 -0
- package/dist/src/lib/parse-design-doc.d.ts.map +1 -0
- package/dist/src/lib/readonly.d.ts +14 -0
- package/dist/src/lib/readonly.d.ts.map +1 -0
- package/dist/src/lib/utils.d.ts +72 -0
- package/dist/src/lib/utils.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-base-plugin/const.d.ts +3 -0
- package/dist/src/plugins/form-builder-base-plugin/const.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-base-plugin/index.d.ts +7 -0
- package/dist/src/plugins/form-builder-base-plugin/index.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-base-plugin/types.d.ts +12 -0
- package/dist/src/plugins/form-builder-base-plugin/types.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/create-form-confirm.d.ts +7 -0
- package/dist/src/plugins/form-builder-plugin/components/create-form-confirm.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/design-doc-part.d.ts +4 -0
- package/dist/src/plugins/form-builder-plugin/components/design-doc-part.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/design-info.d.ts +6 -0
- package/dist/src/plugins/form-builder-plugin/components/design-info.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/entry-btn.d.ts +3 -0
- package/dist/src/plugins/form-builder-plugin/components/entry-btn.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/fields-part.d.ts +4 -0
- package/dist/src/plugins/form-builder-plugin/components/fields-part.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/follow-up.d.ts +3 -0
- package/dist/src/plugins/form-builder-plugin/components/follow-up.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/msg-part.d.ts +3 -0
- package/dist/src/plugins/form-builder-plugin/components/msg-part.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/opening-lines.d.ts +3 -0
- package/dist/src/plugins/form-builder-plugin/components/opening-lines.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/components/suggestion-part.d.ts +5 -0
- package/dist/src/plugins/form-builder-plugin/components/suggestion-part.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/const/index.d.ts +12 -0
- package/dist/src/plugins/form-builder-plugin/const/index.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/hooks/index.d.ts +4 -0
- package/dist/src/plugins/form-builder-plugin/hooks/index.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/hooks/use-fields-confirmed.d.ts +2 -0
- package/dist/src/plugins/form-builder-plugin/hooks/use-fields-confirmed.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/index.d.ts +30 -0
- package/dist/src/plugins/form-builder-plugin/index.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/types.d.ts +28 -0
- package/dist/src/plugins/form-builder-plugin/types.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/utils/get-render-strategy.d.ts +3 -0
- package/dist/src/plugins/form-builder-plugin/utils/get-render-strategy.d.ts.map +1 -0
- package/dist/src/plugins/form-builder-plugin/utils/index.d.ts +57 -0
- package/dist/src/plugins/form-builder-plugin/utils/index.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/batch-filling-data-manager.d.ts +26 -0
- package/dist/src/plugins/form-filling-plugin/batch-filling-data-manager.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/FormFillingOpeningLines.d.ts +3 -0
- package/dist/src/plugins/form-filling-plugin/components/FormFillingOpeningLines.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/avatar.d.ts +5 -0
- package/dist/src/plugins/form-filling-plugin/components/avatar.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/batch-fill-part.d.ts +4 -0
- package/dist/src/plugins/form-filling-plugin/components/batch-fill-part.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/batch-generator-action.d.ts +14 -0
- package/dist/src/plugins/form-filling-plugin/components/batch-generator-action.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/entry-btn.d.ts +3 -0
- package/dist/src/plugins/form-filling-plugin/components/entry-btn.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/first-batch-generating-animation.d.ts +2 -0
- package/dist/src/plugins/form-filling-plugin/components/first-batch-generating-animation.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/generated-data-counter.d.ts +5 -0
- package/dist/src/plugins/form-filling-plugin/components/generated-data-counter.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/mode-select.d.ts +2 -0
- package/dist/src/plugins/form-filling-plugin/components/mode-select.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/msg-part.d.ts +3 -0
- package/dist/src/plugins/form-filling-plugin/components/msg-part.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/non-first-batch-generating-animation.d.ts +2 -0
- package/dist/src/plugins/form-filling-plugin/components/non-first-batch-generating-animation.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/components/single-fill-part.d.ts +4 -0
- package/dist/src/plugins/form-filling-plugin/components/single-fill-part.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/const.d.ts +615 -0
- package/dist/src/plugins/form-filling-plugin/const.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/hooks/use-conversation-id-in-ctx.d.ts +3 -0
- package/dist/src/plugins/form-filling-plugin/hooks/use-conversation-id-in-ctx.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/hooks/use-fields-data.d.ts +4 -0
- package/dist/src/plugins/form-filling-plugin/hooks/use-fields-data.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/index.d.ts +22 -0
- package/dist/src/plugins/form-filling-plugin/index.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/types.d.ts +22 -0
- package/dist/src/plugins/form-filling-plugin/types.d.ts.map +1 -0
- package/dist/src/plugins/form-filling-plugin/utils.d.ts +6 -0
- package/dist/src/plugins/form-filling-plugin/utils.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/avatar.d.ts +5 -0
- package/dist/src/plugins/report-query-plugin/components/avatar.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/query-entry-btn.d.ts +3 -0
- package/dist/src/plugins/report-query-plugin/components/query-entry-btn.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/query-msg-part.d.ts +3 -0
- package/dist/src/plugins/report-query-plugin/components/query-msg-part.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/query-opening-lines.d.ts +2 -0
- package/dist/src/plugins/report-query-plugin/components/query-opening-lines.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/CreatedSourceMsg.d.ts +7 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/CreatedSourceMsg.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/DataTableCard.d.ts +5 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/DataTableCard.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/DataTableFields.d.ts +18 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/DataTableFields.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/FilterCondition.d.ts +4 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/FilterCondition.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/FormulaField.d.ts +8 -0
- package/dist/src/plugins/report-query-plugin/components/result-cards/FormulaField.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/const.d.ts +5 -0
- package/dist/src/plugins/report-query-plugin/const.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/index.d.ts +19 -0
- package/dist/src/plugins/report-query-plugin/index.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/types.d.ts +18 -0
- package/dist/src/plugins/report-query-plugin/types.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/build-dash-component.d.ts +17 -0
- package/dist/src/plugins/report-query-plugin/utils/build-dash-component.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/create-default-dash-styles.d.ts +30 -0
- package/dist/src/plugins/report-query-plugin/utils/create-default-dash-styles.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/create-default-widget-attr-list.d.ts +60 -0
- package/dist/src/plugins/report-query-plugin/utils/create-default-widget-attr-list.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/field-enhance.d.ts +31 -0
- package/dist/src/plugins/report-query-plugin/utils/field-enhance.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/get-field-group.d.ts +208 -0
- package/dist/src/plugins/report-query-plugin/utils/get-field-group.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/get-field-icon.d.ts +4 -0
- package/dist/src/plugins/report-query-plugin/utils/get-field-icon.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/get-group-rule.d.ts +4 -0
- package/dist/src/plugins/report-query-plugin/utils/get-group-rule.d.ts.map +1 -0
- package/dist/src/plugins/report-query-plugin/utils/index.d.ts +5 -0
- package/dist/src/plugins/report-query-plugin/utils/index.d.ts.map +1 -0
- package/dist/src/sdk.impl.d.ts +44 -0
- package/dist/src/sdk.impl.d.ts.map +1 -0
- package/dist/src/store/context.d.ts +12 -0
- package/dist/src/store/context.d.ts.map +1 -0
- package/dist/src/store/index.d.ts +14 -0
- package/dist/src/store/index.d.ts.map +1 -0
- package/dist/src/stories/FormulaField.stories.d.ts +24 -0
- package/dist/src/stories/FormulaField.stories.d.ts.map +1 -0
- package/package.json +5 -4
- package/src/components/biz-comp/FakeBotMsg.tsx +1 -1
- package/src/components/biz-comp/FieldChecker.tsx +2 -2
- package/src/components/biz-comp/FieldCheckerListMsg.tsx +3 -3
- package/src/components/biz-comp/FieldValueChecker.tsx +1 -1
- package/src/components/biz-comp/SubformFieldsValueChecker.tsx +1 -1
- package/src/components/biz-comp/chat-client.tsx +3 -3
- package/src/components/biz-comp/conversation.tsx +1 -1
- package/src/components/biz-comp/dash-widget-icon.tsx +1 -1
- package/src/components/biz-comp/field-icon.tsx +2 -2
- package/src/components/biz-comp/markdown-part.tsx +3 -3
- package/src/components/biz-comp/message-content.tsx +1 -1
- package/src/components/biz-comp/messages.tsx +5 -2
- package/src/components/biz-comp/multi-modal-input/clear-btn.tsx +2 -2
- package/src/components/biz-comp/multi-modal-input/index.tsx +4 -4
- package/src/components/biz-comp/multi-modal-input/prompt-input.tsx +2 -2
- package/src/components/biz-comp/multi-modal-input/voice-btn.tsx +2 -2
- package/src/components/biz-comp/preview-message-wrapper.tsx +14 -7
- package/src/components/biz-comp/preview-message.tsx +5 -5
- package/src/components/biz-comp/suggestions.tsx +2 -2
- package/src/components/web-comp/fields-previewer-web-component.ts +1 -1
- package/src/const/ui.ts +1 -1
- package/src/hooks/use-streaming-anchor.ts +42 -0
- package/src/plugins/form-builder-plugin/components/create-form-confirm.tsx +4 -4
- package/src/plugins/form-builder-plugin/components/design-info.tsx +3 -3
- package/src/plugins/form-builder-plugin/components/entry-btn.tsx +3 -3
- package/src/plugins/form-builder-plugin/components/fields-part.tsx +2 -2
- package/src/plugins/form-builder-plugin/components/follow-up.tsx +2 -2
- package/src/plugins/form-filling-plugin/components/FormFillingOpeningLines.tsx +1 -1
- package/src/plugins/form-filling-plugin/components/avatar.tsx +2 -2
- package/src/plugins/form-filling-plugin/components/batch-generator-action.tsx +1 -1
- package/src/plugins/form-filling-plugin/components/entry-btn.tsx +3 -3
- package/src/plugins/form-filling-plugin/components/first-batch-generating-animation.tsx +2 -2
- package/src/plugins/form-filling-plugin/components/generated-data-counter.tsx +1 -1
- package/src/plugins/form-filling-plugin/components/mode-select.tsx +1 -1
- package/src/plugins/form-filling-plugin/components/non-first-batch-generating-animation.tsx +3 -3
- package/src/plugins/form-filling-plugin/components/single-fill-part.tsx +1 -1
- package/src/plugins/report-query-plugin/components/avatar.tsx +2 -2
- package/src/plugins/report-query-plugin/components/query-entry-btn.tsx +2 -2
- package/src/plugins/report-query-plugin/components/query-opening-lines.tsx +1 -1
- package/src/plugins/report-query-plugin/components/result-cards/CreatedSourceMsg.tsx +1 -1
- package/src/plugins/report-query-plugin/components/result-cards/DataTableCard.tsx +3 -3
- package/src/plugins/report-query-plugin/components/result-cards/DataTableFields.tsx +3 -3
- package/src/plugins/report-query-plugin/components/result-cards/FormulaField.tsx +2 -2
- package/src/plugins/report-query-plugin/const.ts +1 -1
- package/src/style.css +2 -0
- package/tsconfig.json +5 -5
- package/src/components/bs-ui/abs-fullscreen-gradient-bg.tsx +0 -35
- package/src/components/bs-ui/attachment-part-group.tsx +0 -35
- package/src/components/bs-ui/attachment-part.tsx +0 -179
- package/src/components/bs-ui/attachments-previewer.tsx +0 -324
- package/src/components/bs-ui/base-button.tsx +0 -49
- package/src/components/bs-ui/border-animation.tsx +0 -107
- package/src/components/bs-ui/border-color-animation.tsx +0 -66
- package/src/components/bs-ui/bot-avatar-name.tsx +0 -25
- package/src/components/bs-ui/bot-icon.tsx +0 -23
- package/src/components/bs-ui/bs-icons.tsx +0 -1115
- package/src/components/bs-ui/card-field.tsx +0 -23
- package/src/components/bs-ui/card.tsx +0 -36
- package/src/components/bs-ui/chat-area-header.tsx +0 -65
- package/src/components/bs-ui/circle-checker.tsx +0 -66
- package/src/components/bs-ui/collapsible-txt-msg.tsx +0 -63
- package/src/components/bs-ui/confirm-dialog.tsx +0 -139
- package/src/components/bs-ui/fields-design-info-table.tsx +0 -160
- package/src/components/bs-ui/fields-generating-indicator.tsx +0 -95
- package/src/components/bs-ui/fields-portal.tsx +0 -18
- package/src/components/bs-ui/fields-previewer.tsx +0 -210
- package/src/components/bs-ui/font-icon.tsx +0 -17
- package/src/components/bs-ui/form-info-editor.tsx +0 -259
- package/src/components/bs-ui/formula-tag.tsx +0 -32
- package/src/components/bs-ui/generate-animation.tsx +0 -56
- package/src/components/bs-ui/icon-btn.tsx +0 -43
- package/src/components/bs-ui/img-part.tsx +0 -27
- package/src/components/bs-ui/line-checker.tsx +0 -160
- package/src/components/bs-ui/linear-gradient-border-btn.tsx +0 -48
- package/src/components/bs-ui/linear-gradient-color-bg-animation.tsx +0 -103
- package/src/components/bs-ui/number-part.tsx +0 -46
- package/src/components/bs-ui/option-item.tsx +0 -28
- package/src/components/bs-ui/previewer-header.tsx +0 -233
- package/src/components/bs-ui/primary-confirm-btn.tsx +0 -58
- package/src/components/bs-ui/primary-entry-btn.tsx +0 -48
- package/src/components/bs-ui/scroll-to-bottom-btn.tsx +0 -28
- package/src/components/bs-ui/split-line.tsx +0 -9
- package/src/components/bs-ui/square-checker.tsx +0 -87
- package/src/components/bs-ui/tab-radio-group.tsx +0 -82
- package/src/components/bs-ui/tooltip.tsx +0 -53
- package/src/components/bs-ui/user-txt-msg-bubble.tsx +0 -19
- package/src/components/bs-ui/warning-msg.tsx +0 -27
- package/src/stories/AbsFullscreenGradientBg.stories.tsx +0 -36
- package/src/stories/AttachmentPart.stories.tsx +0 -122
- package/src/stories/AttachmentPartGroup.stories.tsx +0 -151
- package/src/stories/AttachmentsPreviewer.stories.tsx +0 -306
- package/src/stories/BaseButton.stories.tsx +0 -33
- package/src/stories/BorderAnimation.stories.tsx +0 -116
- package/src/stories/BorderColorAnimation.stories.tsx +0 -63
- package/src/stories/BotAvatarAndName.stories.ts +0 -24
- package/src/stories/BotIcon.stories.ts +0 -22
- package/src/stories/BsTooltip.stories.tsx +0 -32
- package/src/stories/Card.stories.tsx +0 -28
- package/src/stories/CardField.stories.tsx +0 -87
- package/src/stories/ChatAreaHeader.stories.ts +0 -26
- package/src/stories/CircleChecker.stories.tsx +0 -89
- package/src/stories/CollapsibleTextMsg.stories.ts +0 -44
- package/src/stories/ConfirmDialog.stories.tsx +0 -123
- package/src/stories/DashWidgetIcon.stories.tsx +0 -132
- package/src/stories/FormInfoEditor.stories.tsx +0 -173
- package/src/stories/FormulaTag.stories.tsx +0 -68
- package/src/stories/GenerateAnimation.stories.ts +0 -20
- package/src/stories/IconBtn.stories.tsx +0 -32
- package/src/stories/IconLib.tsx +0 -45
- package/src/stories/Icons.stories.ts +0 -22
- package/src/stories/ImgMsgPart.stories.tsx +0 -42
- package/src/stories/LineChecker.stories.tsx +0 -134
- package/src/stories/LinearGradientBorderBtn.stories.tsx +0 -86
- package/src/stories/LinearGradientColorBgAnimation.stories.tsx +0 -60
- package/src/stories/NumbersMsgPart.stories.tsx +0 -42
- package/src/stories/OptionItem.stories.tsx +0 -77
- package/src/stories/PreviewerHeader.stories.tsx +0 -91
- package/src/stories/PrimaryConfirmBtn.stories.tsx +0 -60
- package/src/stories/PrimaryEntryBtn.stories.tsx +0 -74
- package/src/stories/ScrollToBottom.stories.tsx +0 -24
- package/src/stories/SplitLine.stories.tsx +0 -40
- package/src/stories/SquareChecker.stories.tsx +0 -96
- package/src/stories/TabRadioGroup.stories.tsx +0 -84
- package/src/stories/UserTextMsgBubble.stories.ts +0 -24
- package/src/stories/WarningMessage.stories.tsx +0 -23
- package/src/stories/assets/accessibility.png +0 -0
- package/src/stories/assets/accessibility.svg +0 -1
- package/src/stories/assets/addon-library.png +0 -0
- package/src/stories/assets/assets.png +0 -0
- package/src/stories/assets/avif-test-image.avif +0 -0
- package/src/stories/assets/context.png +0 -0
- package/src/stories/assets/demo.css +0 -539
- package/src/stories/assets/demo_index.html +0 -7988
- package/src/stories/assets/discord.svg +0 -1
- package/src/stories/assets/docs.png +0 -0
- package/src/stories/assets/figma-plugin.png +0 -0
- package/src/stories/assets/github.svg +0 -1
- package/src/stories/assets/iconfont.css +0 -1377
- package/src/stories/assets/iconfont.eot +0 -0
- package/src/stories/assets/iconfont.json +0 -2382
- package/src/stories/assets/iconfont.svg +0 -697
- package/src/stories/assets/iconfont.ttf +0 -0
- package/src/stories/assets/iconfont.woff +0 -0
- package/src/stories/assets/iconfont.woff2 +0 -0
- package/src/stories/assets/share.png +0 -0
- package/src/stories/assets/styling.png +0 -0
- package/src/stories/assets/testing.png +0 -0
- package/src/stories/assets/theming.png +0 -0
- package/src/stories/assets/tutorials.svg +0 -1
- package/src/stories/assets/youtube.svg +0 -1
- package/src/stories/fields-design-info-table.stories.tsx +0 -203
- package/src/stories/fields-generating.stories.tsx +0 -41
- package/src/stories/fields-previewer.stories.tsx +0 -77
|
@@ -1,306 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
-
|
|
3
|
-
import { AttachmentsPreviewer, AttachmentItem } from '@/components/bs-ui/attachments-previewer';
|
|
4
|
-
|
|
5
|
-
const sampleImages: AttachmentItem[] = [
|
|
6
|
-
{
|
|
7
|
-
id: '1',
|
|
8
|
-
url: 'https://images.unsplash.com/photo-1509042239860-f550ce710b93?w=200&h=200&fit=crop',
|
|
9
|
-
alt: 'Coffee',
|
|
10
|
-
contentType: 'image/jpeg',
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
id: '2',
|
|
14
|
-
url: 'https://images.unsplash.com/photo-1543466835-00a7907e9de1?w=200&h=200&fit=crop',
|
|
15
|
-
alt: 'Dog',
|
|
16
|
-
contentType: 'image/jpeg',
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
id: '3',
|
|
20
|
-
url: 'https://images.unsplash.com/photo-1514888286974-6c03e2ca1dba?w=200&h=200&fit=crop',
|
|
21
|
-
alt: 'Cat',
|
|
22
|
-
contentType: 'image/jpeg',
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
id: '4',
|
|
26
|
-
url: 'https://images.unsplash.com/photo-1495474472287-4d71bcdd2085?w=200&h=200&fit=crop',
|
|
27
|
-
alt: 'Coffee cup',
|
|
28
|
-
contentType: 'image/jpeg',
|
|
29
|
-
},
|
|
30
|
-
{
|
|
31
|
-
id: '5',
|
|
32
|
-
url: 'https://images.unsplash.com/photo-1507003211169-0a1dd7228f2d?w=200&h=200&fit=crop',
|
|
33
|
-
alt: 'Portrait',
|
|
34
|
-
contentType: 'image/jpeg',
|
|
35
|
-
},
|
|
36
|
-
];
|
|
37
|
-
|
|
38
|
-
const manyImages: AttachmentItem[] = [
|
|
39
|
-
...sampleImages,
|
|
40
|
-
{
|
|
41
|
-
id: '6',
|
|
42
|
-
url: 'https://images.unsplash.com/photo-1518770660439-4636190af475?w=200&h=200&fit=crop',
|
|
43
|
-
alt: 'Tech',
|
|
44
|
-
contentType: 'image/jpeg',
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
id: '7',
|
|
48
|
-
url: 'https://images.unsplash.com/photo-1493976040374-85c8e12f0c0e?w=200&h=200&fit=crop',
|
|
49
|
-
alt: 'Japan',
|
|
50
|
-
contentType: 'image/jpeg',
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
id: '8',
|
|
54
|
-
url: 'https://images.unsplash.com/photo-1501854140801-50d01698950b?w=200&h=200&fit=crop',
|
|
55
|
-
alt: 'Nature',
|
|
56
|
-
contentType: 'image/jpeg',
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
id: '9',
|
|
60
|
-
url: 'https://images.unsplash.com/photo-1470071459604-3b5ec3a7fe05?w=200&h=200&fit=crop',
|
|
61
|
-
alt: 'Fog',
|
|
62
|
-
contentType: 'image/jpeg',
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
id: '10',
|
|
66
|
-
url: 'https://images.unsplash.com/photo-1441974231531-c6227db76b6e?w=200&h=200&fit=crop',
|
|
67
|
-
alt: 'Forest',
|
|
68
|
-
contentType: 'image/jpeg',
|
|
69
|
-
},
|
|
70
|
-
];
|
|
71
|
-
|
|
72
|
-
const sampleFiles: AttachmentItem[] = [
|
|
73
|
-
{
|
|
74
|
-
id: 'file-xlsx',
|
|
75
|
-
url: '',
|
|
76
|
-
alt: 'report.xlsx',
|
|
77
|
-
contentType: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
id: 'file-csv',
|
|
81
|
-
url: '',
|
|
82
|
-
alt: 'data.csv',
|
|
83
|
-
contentType: 'text/csv',
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
id: 'file-txt',
|
|
87
|
-
url: '',
|
|
88
|
-
alt: 'notes.txt',
|
|
89
|
-
contentType: 'text/plain',
|
|
90
|
-
},
|
|
91
|
-
{
|
|
92
|
-
id: 'file-unknown',
|
|
93
|
-
url: '',
|
|
94
|
-
alt: 'archive.bin',
|
|
95
|
-
contentType: 'application/x-unknown',
|
|
96
|
-
},
|
|
97
|
-
];
|
|
98
|
-
|
|
99
|
-
const meta: Meta<typeof AttachmentsPreviewer> = {
|
|
100
|
-
title: 'Example/Chat/AttachmentsPreviewer',
|
|
101
|
-
component: AttachmentsPreviewer,
|
|
102
|
-
tags: ['autodocs'],
|
|
103
|
-
parameters: {
|
|
104
|
-
layout: 'centered',
|
|
105
|
-
},
|
|
106
|
-
args: {},
|
|
107
|
-
decorators: [
|
|
108
|
-
(Story) => (
|
|
109
|
-
<div style={{ width: 308 }}>
|
|
110
|
-
<Story />
|
|
111
|
-
</div>
|
|
112
|
-
),
|
|
113
|
-
],
|
|
114
|
-
};
|
|
115
|
-
|
|
116
|
-
export default meta;
|
|
117
|
-
type Story = StoryObj<typeof meta>;
|
|
118
|
-
|
|
119
|
-
export const Base: Story = {
|
|
120
|
-
args: {
|
|
121
|
-
attachments: sampleImages,
|
|
122
|
-
},
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
export const FewImages: Story = {
|
|
126
|
-
args: {
|
|
127
|
-
attachments: sampleImages.slice(0, 3),
|
|
128
|
-
},
|
|
129
|
-
decorators: [
|
|
130
|
-
(Story) => (
|
|
131
|
-
<div style={{ width: 220 }}>
|
|
132
|
-
<Story />
|
|
133
|
-
</div>
|
|
134
|
-
),
|
|
135
|
-
],
|
|
136
|
-
};
|
|
137
|
-
|
|
138
|
-
export const ManyImages: Story = {
|
|
139
|
-
args: {
|
|
140
|
-
attachments: manyImages,
|
|
141
|
-
onImageRemove: (attachment, index) => {
|
|
142
|
-
alert(`Remove image ${index + 1}: ${attachment.alt}`);
|
|
143
|
-
},
|
|
144
|
-
},
|
|
145
|
-
decorators: [
|
|
146
|
-
(Story) => (
|
|
147
|
-
<div style={{ width: 350 }}>
|
|
148
|
-
<Story />
|
|
149
|
-
</div>
|
|
150
|
-
),
|
|
151
|
-
],
|
|
152
|
-
};
|
|
153
|
-
|
|
154
|
-
export const WithClickHandler: Story = {
|
|
155
|
-
args: {
|
|
156
|
-
attachments: sampleImages,
|
|
157
|
-
onImageClick: (attachment, index) => {
|
|
158
|
-
alert(`Clicked image ${index + 1}: ${attachment.alt}`);
|
|
159
|
-
},
|
|
160
|
-
},
|
|
161
|
-
};
|
|
162
|
-
|
|
163
|
-
export const WithRemoveHandler: Story = {
|
|
164
|
-
args: {
|
|
165
|
-
attachments: sampleImages,
|
|
166
|
-
onImageRemove: (attachment, index) => {
|
|
167
|
-
alert(`Remove image ${index + 1}: ${attachment.alt}`);
|
|
168
|
-
},
|
|
169
|
-
},
|
|
170
|
-
};
|
|
171
|
-
|
|
172
|
-
export const CustomSize: Story = {
|
|
173
|
-
args: {
|
|
174
|
-
attachments: sampleImages,
|
|
175
|
-
imageSize: 80,
|
|
176
|
-
gap: 12,
|
|
177
|
-
},
|
|
178
|
-
decorators: [
|
|
179
|
-
(Story) => (
|
|
180
|
-
<div style={{ width: 400 }}>
|
|
181
|
-
<Story />
|
|
182
|
-
</div>
|
|
183
|
-
),
|
|
184
|
-
],
|
|
185
|
-
};
|
|
186
|
-
|
|
187
|
-
export const SmallSize: Story = {
|
|
188
|
-
args: {
|
|
189
|
-
attachments: sampleImages,
|
|
190
|
-
imageSize: 40,
|
|
191
|
-
gap: 8,
|
|
192
|
-
},
|
|
193
|
-
decorators: [
|
|
194
|
-
(Story) => (
|
|
195
|
-
<div style={{ width: 250 }}>
|
|
196
|
-
<Story />
|
|
197
|
-
</div>
|
|
198
|
-
),
|
|
199
|
-
],
|
|
200
|
-
};
|
|
201
|
-
|
|
202
|
-
export const SingleImage: Story = {
|
|
203
|
-
args: {
|
|
204
|
-
attachments: sampleImages.slice(0, 1),
|
|
205
|
-
},
|
|
206
|
-
};
|
|
207
|
-
|
|
208
|
-
export const TwoImages: Story = {
|
|
209
|
-
args: {
|
|
210
|
-
attachments: sampleImages.slice(0, 2),
|
|
211
|
-
},
|
|
212
|
-
};
|
|
213
|
-
|
|
214
|
-
export const FullWidth: Story = {
|
|
215
|
-
args: {
|
|
216
|
-
attachments: manyImages,
|
|
217
|
-
},
|
|
218
|
-
decorators: [
|
|
219
|
-
(Story) => (
|
|
220
|
-
<div style={{ width: 600 }}>
|
|
221
|
-
<Story />
|
|
222
|
-
</div>
|
|
223
|
-
),
|
|
224
|
-
],
|
|
225
|
-
};
|
|
226
|
-
|
|
227
|
-
export const WithLoadingItems: Story = {
|
|
228
|
-
args: {
|
|
229
|
-
attachments: [
|
|
230
|
-
...sampleImages.slice(0, 2),
|
|
231
|
-
{
|
|
232
|
-
id: 'loading-1',
|
|
233
|
-
url: '',
|
|
234
|
-
alt: 'Uploading file 1',
|
|
235
|
-
isLoading: true,
|
|
236
|
-
contentType: 'application/vnd.ms-excel',
|
|
237
|
-
},
|
|
238
|
-
{
|
|
239
|
-
id: 'loading-2',
|
|
240
|
-
url: '',
|
|
241
|
-
alt: 'Uploading file 2',
|
|
242
|
-
isLoading: true,
|
|
243
|
-
contentType: 'text/csv',
|
|
244
|
-
},
|
|
245
|
-
],
|
|
246
|
-
onImageRemove: (attachment, index) => {
|
|
247
|
-
alert(`Remove image ${index + 1}: ${attachment.alt}`);
|
|
248
|
-
},
|
|
249
|
-
},
|
|
250
|
-
};
|
|
251
|
-
|
|
252
|
-
export const MixedLoadingAndLoaded: Story = {
|
|
253
|
-
args: {
|
|
254
|
-
attachments: [
|
|
255
|
-
sampleImages[0],
|
|
256
|
-
{
|
|
257
|
-
id: 'loading-1',
|
|
258
|
-
url: '',
|
|
259
|
-
alt: 'Uploading...',
|
|
260
|
-
isLoading: true,
|
|
261
|
-
contentType: 'image/png',
|
|
262
|
-
},
|
|
263
|
-
sampleImages[1],
|
|
264
|
-
sampleImages[2],
|
|
265
|
-
{
|
|
266
|
-
id: 'loading-2',
|
|
267
|
-
url: '',
|
|
268
|
-
alt: 'Uploading...',
|
|
269
|
-
isLoading: true,
|
|
270
|
-
contentType: 'text/plain',
|
|
271
|
-
},
|
|
272
|
-
],
|
|
273
|
-
onImageRemove: (attachment, index) => {
|
|
274
|
-
alert(`Remove image ${index + 1}: ${attachment.alt}`);
|
|
275
|
-
},
|
|
276
|
-
},
|
|
277
|
-
};
|
|
278
|
-
|
|
279
|
-
export const NonImageFiles: Story = {
|
|
280
|
-
args: {
|
|
281
|
-
attachments: sampleFiles,
|
|
282
|
-
onImageRemove: (attachment, index) => {
|
|
283
|
-
alert(`Remove file ${index + 1}: ${attachment.alt}`);
|
|
284
|
-
},
|
|
285
|
-
},
|
|
286
|
-
decorators: [
|
|
287
|
-
(Story) => (
|
|
288
|
-
<div style={{ width: 260 }}>
|
|
289
|
-
<Story />
|
|
290
|
-
</div>
|
|
291
|
-
),
|
|
292
|
-
],
|
|
293
|
-
};
|
|
294
|
-
|
|
295
|
-
export const MixedFilesAndImages: Story = {
|
|
296
|
-
args: {
|
|
297
|
-
attachments: [...sampleImages.slice(0, 2), ...sampleFiles],
|
|
298
|
-
},
|
|
299
|
-
decorators: [
|
|
300
|
-
(Story) => (
|
|
301
|
-
<div style={{ width: 360 }}>
|
|
302
|
-
<Story />
|
|
303
|
-
</div>
|
|
304
|
-
),
|
|
305
|
-
],
|
|
306
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
-
|
|
3
|
-
import { BaseButton } from '@/components/bs-ui/base-button';
|
|
4
|
-
import { ColorfulEditIcon, DockIcon } from '@/components/bs-ui/bs-icons';
|
|
5
|
-
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Example/Button/BaseButton',
|
|
8
|
-
component: BaseButton,
|
|
9
|
-
tags: ['autodocs'],
|
|
10
|
-
parameters: {
|
|
11
|
-
layout: 'centered',
|
|
12
|
-
},
|
|
13
|
-
args: {
|
|
14
|
-
children: 'AI填报示例数据',
|
|
15
|
-
icon: <DockIcon />,
|
|
16
|
-
},
|
|
17
|
-
} satisfies Meta<typeof BaseButton>;
|
|
18
|
-
|
|
19
|
-
export default meta;
|
|
20
|
-
|
|
21
|
-
type Story = StoryObj<typeof meta>;
|
|
22
|
-
|
|
23
|
-
export const Base: Story = {
|
|
24
|
-
args: {
|
|
25
|
-
icon: <ColorfulEditIcon />,
|
|
26
|
-
},
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
export const Hover: Story = {
|
|
30
|
-
parameters: {
|
|
31
|
-
pseudo: { hover: true },
|
|
32
|
-
},
|
|
33
|
-
};
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
-
|
|
3
|
-
import { BorderAnimation } from '@/components/bs-ui/border-animation';
|
|
4
|
-
|
|
5
|
-
const meta = {
|
|
6
|
-
title: 'Animation/BorderAnimation',
|
|
7
|
-
component: BorderAnimation,
|
|
8
|
-
tags: ['autodocs'],
|
|
9
|
-
parameters: {
|
|
10
|
-
layout: 'centered',
|
|
11
|
-
},
|
|
12
|
-
args: {},
|
|
13
|
-
} satisfies Meta<typeof BorderAnimation>;
|
|
14
|
-
|
|
15
|
-
export default meta;
|
|
16
|
-
type Story = StoryObj<typeof meta>;
|
|
17
|
-
|
|
18
|
-
export const Default: Story = {
|
|
19
|
-
args: {
|
|
20
|
-
children: (
|
|
21
|
-
<div className="flex items-center gap-[6px] bg-white px-[10px] py-[4px] rounded-[4px]">
|
|
22
|
-
<span className="text-[#999] text-[14px]">
|
|
23
|
-
数据生成中,可点击下方按钮暂停
|
|
24
|
-
</span>
|
|
25
|
-
</div>
|
|
26
|
-
),
|
|
27
|
-
},
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
export const WithCustomContent: Story = {
|
|
31
|
-
args: {
|
|
32
|
-
children: (
|
|
33
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
34
|
-
<h3 className="text-[16px] font-medium text-[#333]">标题内容</h3>
|
|
35
|
-
<p className="text-[14px] text-[#666] mt-1">
|
|
36
|
-
这是一段描述文字,展示边框动画效果。
|
|
37
|
-
</p>
|
|
38
|
-
</div>
|
|
39
|
-
),
|
|
40
|
-
},
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export const LargerRadius: Story = {
|
|
44
|
-
args: {
|
|
45
|
-
borderRadius: 12,
|
|
46
|
-
children: (
|
|
47
|
-
<div className="bg-white px-4 py-3 rounded-[12px]">
|
|
48
|
-
<p className="text-[14px] text-[#666]">圆角 12px 的边框动画</p>
|
|
49
|
-
</div>
|
|
50
|
-
),
|
|
51
|
-
},
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
export const SlowAnimation: Story = {
|
|
55
|
-
args: {
|
|
56
|
-
duration: 5,
|
|
57
|
-
children: (
|
|
58
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
59
|
-
<p className="text-[14px] text-[#666]">慢速动画(5秒一圈)</p>
|
|
60
|
-
</div>
|
|
61
|
-
),
|
|
62
|
-
},
|
|
63
|
-
};
|
|
64
|
-
|
|
65
|
-
export const FastAnimation: Story = {
|
|
66
|
-
args: {
|
|
67
|
-
duration: 1,
|
|
68
|
-
children: (
|
|
69
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
70
|
-
<p className="text-[14px] text-[#666]">快速动画(1秒一圈)</p>
|
|
71
|
-
</div>
|
|
72
|
-
),
|
|
73
|
-
},
|
|
74
|
-
};
|
|
75
|
-
|
|
76
|
-
export const CustomGradient: Story = {
|
|
77
|
-
args: {
|
|
78
|
-
gradient:
|
|
79
|
-
'linear-gradient(180deg, #FF84B4 0%, #FF0265 50%, #FFB1FA 100%)',
|
|
80
|
-
children: (
|
|
81
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
82
|
-
<p className="text-[14px] text-[#666]">自定义渐变色(粉色系)</p>
|
|
83
|
-
</div>
|
|
84
|
-
),
|
|
85
|
-
},
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
export const CustomClassName: Story = {
|
|
89
|
-
args: {
|
|
90
|
-
className: 'w-[300px]',
|
|
91
|
-
children: (
|
|
92
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
93
|
-
<p className="text-[14px] text-[#666]">自定义宽度 300px</p>
|
|
94
|
-
</div>
|
|
95
|
-
),
|
|
96
|
-
},
|
|
97
|
-
};
|
|
98
|
-
|
|
99
|
-
export const FullWidth: Story = {
|
|
100
|
-
decorators: [
|
|
101
|
-
(Story) => (
|
|
102
|
-
<div style={{ width: '500px' }}>
|
|
103
|
-
<Story />
|
|
104
|
-
</div>
|
|
105
|
-
),
|
|
106
|
-
],
|
|
107
|
-
args: {
|
|
108
|
-
children: (
|
|
109
|
-
<div className="bg-white px-4 py-3 rounded-[4px]">
|
|
110
|
-
<p className="text-[14px] text-[#666]">
|
|
111
|
-
宽度 100%,自动填满父容器
|
|
112
|
-
</p>
|
|
113
|
-
</div>
|
|
114
|
-
),
|
|
115
|
-
},
|
|
116
|
-
};
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
-
|
|
3
|
-
import { BorderColorAnimation } from '@/components/bs-ui/border-color-animation';
|
|
4
|
-
|
|
5
|
-
const meta = {
|
|
6
|
-
title: 'Example/Animation/BorderColorAnimation',
|
|
7
|
-
component: BorderColorAnimation,
|
|
8
|
-
tags: ['autodocs'],
|
|
9
|
-
parameters: {
|
|
10
|
-
layout: 'centered',
|
|
11
|
-
},
|
|
12
|
-
args: {},
|
|
13
|
-
} satisfies Meta<typeof BorderColorAnimation>;
|
|
14
|
-
|
|
15
|
-
export default meta;
|
|
16
|
-
type Story = StoryObj<typeof meta>;
|
|
17
|
-
|
|
18
|
-
export const Default: Story = {
|
|
19
|
-
args: {
|
|
20
|
-
width: '600px',
|
|
21
|
-
height: '400px',
|
|
22
|
-
},
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
export const WithContent: Story = {
|
|
26
|
-
args: {
|
|
27
|
-
width: '600px',
|
|
28
|
-
height: '400px',
|
|
29
|
-
},
|
|
30
|
-
render: (args) => (
|
|
31
|
-
<BorderColorAnimation {...args}>
|
|
32
|
-
<div
|
|
33
|
-
style={{
|
|
34
|
-
display: 'flex',
|
|
35
|
-
alignItems: 'center',
|
|
36
|
-
flexDirection: 'column',
|
|
37
|
-
justifyContent: 'center',
|
|
38
|
-
height: '100%',
|
|
39
|
-
color: '#333',
|
|
40
|
-
}}
|
|
41
|
-
>
|
|
42
|
-
<div style={{ textAlign: 'center' }}>
|
|
43
|
-
<h2 style={{ margin: '0 0 12px 0' }}>Animated Border</h2>
|
|
44
|
-
<p style={{ margin: 0 }}>Content inside the animated border frame</p>
|
|
45
|
-
</div>
|
|
46
|
-
</div>
|
|
47
|
-
</BorderColorAnimation>
|
|
48
|
-
),
|
|
49
|
-
};
|
|
50
|
-
|
|
51
|
-
export const SmallSize: Story = {
|
|
52
|
-
args: {
|
|
53
|
-
width: '300px',
|
|
54
|
-
height: '200px',
|
|
55
|
-
},
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
export const SquareSize: Story = {
|
|
59
|
-
args: {
|
|
60
|
-
width: '400px',
|
|
61
|
-
height: '400px',
|
|
62
|
-
},
|
|
63
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from "@storybook/react-vite";
|
|
2
|
-
|
|
3
|
-
import { BotAvatarAndName } from "@/components/bs-ui/bot-avatar-name";
|
|
4
|
-
|
|
5
|
-
const meta = {
|
|
6
|
-
title: "Example/Chat/Bot Avatar And Name",
|
|
7
|
-
component: BotAvatarAndName,
|
|
8
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
|
|
9
|
-
tags: ["autodocs"],
|
|
10
|
-
parameters: {
|
|
11
|
-
// More on how to position stories at: https://storybook.js.org/docs/configure/story-layout
|
|
12
|
-
layout: "centered",
|
|
13
|
-
},
|
|
14
|
-
args: {},
|
|
15
|
-
} satisfies Meta<typeof BotAvatarAndName>;
|
|
16
|
-
|
|
17
|
-
export default meta;
|
|
18
|
-
type Story = StoryObj<typeof meta>;
|
|
19
|
-
|
|
20
|
-
export const Base: Story = {
|
|
21
|
-
args: {
|
|
22
|
-
name: "AI表单搭建",
|
|
23
|
-
},
|
|
24
|
-
};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from "@storybook/react-vite";
|
|
2
|
-
|
|
3
|
-
import { BotIcon } from "@/components/bs-ui/bot-icon";
|
|
4
|
-
|
|
5
|
-
const meta = {
|
|
6
|
-
title: "Example/Icons/BotIcon",
|
|
7
|
-
component: BotIcon,
|
|
8
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
|
|
9
|
-
tags: ["autodocs"],
|
|
10
|
-
parameters: {
|
|
11
|
-
// More on how to position stories at: https://storybook.js.org/docs/configure/story-layout
|
|
12
|
-
layout: "centered",
|
|
13
|
-
},
|
|
14
|
-
args: {},
|
|
15
|
-
} satisfies Meta<typeof BotIcon>;
|
|
16
|
-
|
|
17
|
-
export default meta;
|
|
18
|
-
type Story = StoryObj<typeof meta>;
|
|
19
|
-
|
|
20
|
-
export const Base: Story = {
|
|
21
|
-
args: {},
|
|
22
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
-
|
|
3
|
-
import { BsTooltip } from '@/components/bs-ui/tooltip';
|
|
4
|
-
import { TooltipProvider } from '@/components/ui/tooltip';
|
|
5
|
-
import { IconBtn } from '@/components/bs-ui/icon-btn';
|
|
6
|
-
import { ColorfulEditIcon } from '@/components/bs-ui/bs-icons';
|
|
7
|
-
|
|
8
|
-
const meta: Meta<typeof BsTooltip> = {
|
|
9
|
-
title: 'Example/Chat/BsTooltip',
|
|
10
|
-
component: BsTooltip,
|
|
11
|
-
tags: ['autodocs'],
|
|
12
|
-
parameters: {
|
|
13
|
-
layout: 'centered',
|
|
14
|
-
},
|
|
15
|
-
decorators: [
|
|
16
|
-
(Story) => (
|
|
17
|
-
<TooltipProvider delayDuration={100}>
|
|
18
|
-
<Story />
|
|
19
|
-
</TooltipProvider>
|
|
20
|
-
),
|
|
21
|
-
],
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export default meta;
|
|
25
|
-
type Story = StoryObj<typeof meta>;
|
|
26
|
-
|
|
27
|
-
export const Default: Story = {
|
|
28
|
-
args: {
|
|
29
|
-
children: <IconBtn icon={<ColorfulEditIcon />} />,
|
|
30
|
-
content: '编辑消息',
|
|
31
|
-
},
|
|
32
|
-
};
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from "@storybook/react-vite";
|
|
2
|
-
|
|
3
|
-
import { Card } from "@/components/bs-ui/card";
|
|
4
|
-
import { UserIcon } from "@/components/bs-ui/bs-icons";
|
|
5
|
-
|
|
6
|
-
const meta = {
|
|
7
|
-
title: "Example/Chat/Card",
|
|
8
|
-
component: Card,
|
|
9
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
|
|
10
|
-
tags: ["autodocs"],
|
|
11
|
-
parameters: {
|
|
12
|
-
// More on how to position stories at: https://storybook.js.org/docs/configure/story-layout
|
|
13
|
-
layout: "centered",
|
|
14
|
-
},
|
|
15
|
-
args: {},
|
|
16
|
-
} satisfies Meta<typeof Card>;
|
|
17
|
-
|
|
18
|
-
export default meta;
|
|
19
|
-
type Story = StoryObj<typeof meta>;
|
|
20
|
-
|
|
21
|
-
export const Base: Story = {
|
|
22
|
-
args: {
|
|
23
|
-
title: "供应商管理,子表单为产品信息",
|
|
24
|
-
index: 1,
|
|
25
|
-
desc: "用于记录和管理企业供应商的基本信息、资质认证、合作状态等,便于采购部门进行供应商评估和选择。",
|
|
26
|
-
icon: <UserIcon />,
|
|
27
|
-
},
|
|
28
|
-
};
|