@quaffui/quaff 0.1.0-prealpha9 → 1.0.0-alpha1
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/LICENSE +1 -1
- package/README.md +47 -14
- package/dist/classes/QContext.svelte.d.ts +42 -0
- package/dist/classes/QContext.svelte.js +63 -0
- package/dist/classes/QScrollObserver.svelte.d.ts +48 -0
- package/dist/classes/QScrollObserver.svelte.js +107 -0
- package/dist/classes/QTheme.svelte.d.ts +13 -0
- package/dist/classes/QTheme.svelte.js +62 -0
- package/dist/classes/Quaff.svelte.d.ts +15 -0
- package/dist/classes/Quaff.svelte.js +45 -0
- package/dist/components/avatar/QAvatar.scss +101 -0
- package/dist/components/avatar/QAvatar.svelte +42 -42
- package/dist/components/avatar/QAvatar.svelte.d.ts +4 -17
- package/dist/components/avatar/docs.d.ts +2 -2
- package/dist/components/avatar/docs.js +3 -8
- package/dist/components/avatar/docs.props.d.ts +3 -8
- package/dist/components/avatar/docs.props.js +68 -15
- package/dist/components/avatar/index.scss +5 -3
- package/dist/components/avatar/props.d.ts +51 -8
- package/dist/components/breadcrumbs/QBreadcrumbs.scss +10 -0
- package/dist/components/breadcrumbs/QBreadcrumbs.svelte +32 -14
- package/dist/components/breadcrumbs/QBreadcrumbs.svelte.d.ts +4 -13
- package/dist/components/breadcrumbs/QBreadcrumbsEl.scss +10 -0
- package/dist/components/breadcrumbs/QBreadcrumbsEl.svelte +65 -48
- package/dist/components/breadcrumbs/QBreadcrumbsEl.svelte.d.ts +4 -16
- package/dist/components/breadcrumbs/docs.d.ts +2 -2
- package/dist/components/breadcrumbs/docs.js +3 -8
- package/dist/components/breadcrumbs/docs.props.d.ts +5 -16
- package/dist/components/breadcrumbs/docs.props.js +105 -45
- package/dist/components/breadcrumbs/props.d.ts +26 -24
- package/dist/components/button/QBtn.scss +136 -0
- package/dist/components/button/QBtn.svelte +156 -52
- package/dist/components/button/QBtn.svelte.d.ts +4 -23
- package/dist/components/button/docs.d.ts +2 -2
- package/dist/components/button/docs.js +3 -8
- package/dist/components/button/docs.props.d.ts +3 -8
- package/dist/components/button/docs.props.js +174 -37
- package/dist/components/button/props.d.ts +48 -11
- package/dist/components/card/QCard.scss +25 -0
- package/dist/components/card/QCard.svelte +34 -19
- package/dist/components/card/QCard.svelte.d.ts +4 -16
- package/dist/components/card/QCardActions.scss +10 -0
- package/dist/components/card/QCardActions.svelte +23 -15
- package/dist/components/card/QCardActions.svelte.d.ts +4 -12
- package/dist/components/card/QCardSection.scss +10 -0
- package/dist/components/card/QCardSection.svelte +15 -11
- package/dist/components/card/QCardSection.svelte.d.ts +4 -13
- package/dist/components/card/docs.d.ts +4 -4
- package/dist/components/card/docs.js +7 -22
- package/dist/components/card/docs.props.d.ts +7 -24
- package/dist/components/card/docs.props.js +57 -30
- package/dist/components/card/props.d.ts +11 -16
- package/dist/components/checkbox/QCheckbox.svelte +15 -9
- package/dist/components/checkbox/QCheckbox.svelte.d.ts +3 -10
- package/dist/components/checkbox/docs.d.ts +2 -2
- package/dist/components/checkbox/docs.js +3 -3
- package/dist/components/checkbox/docs.props.d.ts +3 -8
- package/dist/components/checkbox/docs.props.js +24 -9
- package/dist/components/checkbox/index.scss +3 -1
- package/dist/components/checkbox/props.d.ts +2 -2
- package/dist/components/chip/QChip.scss +179 -0
- package/dist/components/chip/QChip.svelte +130 -60
- package/dist/components/chip/QChip.svelte.d.ts +4 -25
- package/dist/components/chip/docs.d.ts +2 -2
- package/dist/components/chip/docs.js +3 -16
- package/dist/components/chip/docs.props.d.ts +3 -8
- package/dist/components/chip/docs.props.js +96 -49
- package/dist/components/chip/props.d.ts +27 -29
- package/dist/components/codeBlock/QCodeBlock.svelte +90 -44
- package/dist/components/codeBlock/QCodeBlock.svelte.d.ts +3 -10
- package/dist/components/codeBlock/docs.props.d.ts +3 -8
- package/dist/components/codeBlock/docs.props.js +61 -12
- package/dist/components/codeBlock/props.d.ts +12 -2
- package/dist/components/dialog/{index.scss → QDialog.scss} +12 -14
- package/dist/components/dialog/QDialog.svelte +85 -78
- package/dist/components/dialog/QDialog.svelte.d.ts +9 -24
- package/dist/components/dialog/docs.d.ts +2 -2
- package/dist/components/dialog/docs.js +3 -3
- package/dist/components/dialog/docs.props.d.ts +3 -16
- package/dist/components/dialog/docs.props.js +37 -128
- package/dist/components/dialog/props.d.ts +4 -19
- package/dist/components/drawer/QDrawer.scss +39 -0
- package/dist/components/drawer/QDrawer.svelte +138 -90
- package/dist/components/drawer/QDrawer.svelte.d.ts +9 -28
- package/dist/components/drawer/docs.d.ts +2 -2
- package/dist/components/drawer/docs.js +3 -3
- package/dist/components/drawer/docs.props.d.ts +3 -8
- package/dist/components/drawer/docs.props.js +94 -39
- package/dist/components/drawer/props.d.ts +4 -3
- package/dist/components/footer/QFooter.scss +42 -0
- package/dist/components/footer/QFooter.svelte +99 -24
- package/dist/components/footer/QFooter.svelte.d.ts +4 -14
- package/dist/components/footer/docs.d.ts +2 -2
- package/dist/components/footer/docs.js +3 -3
- package/dist/components/footer/docs.props.d.ts +3 -8
- package/dist/components/footer/docs.props.js +47 -16
- package/dist/components/footer/props.d.ts +15 -9
- package/dist/components/header/QHeader.scss +53 -0
- package/dist/components/header/QHeader.svelte +90 -23
- package/dist/components/header/QHeader.svelte.d.ts +4 -14
- package/dist/components/header/docs.d.ts +2 -0
- package/dist/components/header/docs.js +11 -0
- package/dist/components/header/docs.props.d.ts +7 -0
- package/dist/components/header/docs.props.js +131 -0
- package/dist/components/header/props.d.ts +13 -5
- package/dist/components/icon/{index.scss → QIcon.scss} +2 -4
- package/dist/components/icon/QIcon.svelte +44 -28
- package/dist/components/icon/QIcon.svelte.d.ts +4 -18
- package/dist/components/icon/docs.d.ts +2 -2
- package/dist/components/icon/docs.js +3 -3
- package/dist/components/icon/docs.props.d.ts +3 -8
- package/dist/components/icon/docs.props.js +65 -24
- package/dist/components/icon/props.d.ts +9 -8
- package/dist/components/index.d.ts +5 -2
- package/dist/components/index.js +5 -2
- package/dist/components/input/QInput.svelte +106 -72
- package/dist/components/input/QInput.svelte.d.ts +4 -22
- package/dist/components/input/docs.d.ts +2 -2
- package/dist/components/input/docs.js +5 -71
- package/dist/components/input/docs.props.d.ts +3 -8
- package/dist/components/input/docs.props.js +129 -57
- package/dist/components/input/index.scss +1 -3
- package/dist/components/input/props.d.ts +81 -21
- package/dist/components/input/props.js +1 -13
- package/dist/components/layout/QLayout.scss +174 -0
- package/dist/components/layout/QLayout.svelte +178 -79
- package/dist/components/layout/QLayout.svelte.d.ts +12 -45
- package/dist/components/layout/docs.d.ts +2 -2
- package/dist/components/layout/docs.js +3 -3
- package/dist/components/layout/docs.props.d.ts +3 -8
- package/dist/components/layout/docs.props.js +62 -39
- package/dist/components/layout/props.d.ts +29 -21
- package/dist/components/list/QItem.scss +69 -0
- package/dist/components/list/QItem.svelte +99 -51
- package/dist/components/list/QItem.svelte.d.ts +4 -24
- package/dist/components/list/QItemSection.scss +59 -0
- package/dist/components/list/QItemSection.svelte +63 -37
- package/dist/components/list/QItemSection.svelte.d.ts +4 -15
- package/dist/components/list/QList.scss +30 -0
- package/dist/components/list/QList.svelte +43 -20
- package/dist/components/list/QList.svelte.d.ts +4 -26
- package/dist/components/list/docs.d.ts +4 -2
- package/dist/components/list/docs.js +23 -3
- package/dist/components/list/docs.props.d.ts +11 -40
- package/dist/components/list/docs.props.js +344 -136
- package/dist/components/list/props.d.ts +126 -28
- package/dist/components/list/props.js +1 -25
- package/dist/components/private/ContextReseter.svelte +15 -11
- package/dist/components/private/ContextReseter.svelte.d.ts +4 -8
- package/dist/components/private/QApi.svelte +264 -113
- package/dist/components/private/QApi.svelte.d.ts +3 -6
- package/dist/components/private/QDocs.svelte +119 -68
- package/dist/components/private/QDocs.svelte.d.ts +4 -11
- package/dist/components/private/QDocsSection.svelte +48 -18
- package/dist/components/private/QDocsSection.svelte.d.ts +9 -24
- package/dist/components/private/QIconSnippet.svelte +22 -0
- package/dist/components/private/QIconSnippet.svelte.d.ts +14 -0
- package/dist/components/private/index.d.ts +6 -0
- package/dist/components/private/index.js +6 -0
- package/dist/components/progress/QCircularProgress.scss +63 -0
- package/dist/components/progress/QCircularProgress.svelte +134 -21
- package/dist/components/progress/QCircularProgress.svelte.d.ts +3 -11
- package/dist/components/progress/QLinearProgress.scss +75 -0
- package/dist/components/progress/QLinearProgress.svelte +80 -23
- package/dist/components/progress/QLinearProgress.svelte.d.ts +3 -11
- package/dist/components/progress/docs.d.ts +3 -2
- package/dist/components/progress/docs.js +15 -5
- package/dist/components/progress/docs.props.d.ts +5 -16
- package/dist/components/progress/docs.props.js +287 -41
- package/dist/components/progress/props.d.ts +126 -14
- package/dist/components/radio/QRadio.svelte +16 -9
- package/dist/components/radio/QRadio.svelte.d.ts +3 -11
- package/dist/components/radio/docs.d.ts +2 -2
- package/dist/components/radio/docs.js +4 -26
- package/dist/components/radio/docs.props.d.ts +3 -8
- package/dist/components/radio/docs.props.js +39 -20
- package/dist/components/radio/index.scss +3 -1
- package/dist/components/radio/props.d.ts +26 -6
- package/dist/components/radio/props.js +1 -8
- package/dist/components/railbar/QRailbar.scss +54 -0
- package/dist/components/railbar/QRailbar.svelte +71 -65
- package/dist/components/railbar/QRailbar.svelte.d.ts +4 -13
- package/dist/components/railbar/docs.d.ts +2 -2
- package/dist/components/railbar/docs.js +3 -3
- package/dist/components/railbar/docs.props.d.ts +3 -8
- package/dist/components/railbar/docs.props.js +36 -15
- package/dist/components/railbar/props.d.ts +13 -6
- package/dist/components/select/QSelect.svelte +222 -146
- package/dist/components/select/QSelect.svelte.d.ts +4 -24
- package/dist/components/select/docs.d.ts +2 -2
- package/dist/components/select/docs.js +5 -83
- package/dist/components/select/docs.props.d.ts +3 -8
- package/dist/components/select/docs.props.js +156 -64
- package/dist/components/select/index.scss +25 -10
- package/dist/components/select/props.d.ts +100 -20
- package/dist/components/select/props.js +1 -14
- package/dist/components/separator/QSeparator.scss +54 -0
- package/dist/components/separator/QSeparator.svelte +50 -57
- package/dist/components/separator/QSeparator.svelte.d.ts +3 -14
- package/dist/components/separator/docs.d.ts +3 -2
- package/dist/components/separator/docs.js +14 -4
- package/dist/components/separator/docs.props.d.ts +5 -16
- package/dist/components/separator/docs.props.js +152 -72
- package/dist/components/separator/props.d.ts +84 -16
- package/dist/components/separator/props.js +1 -9
- package/dist/components/switch/QSwitch.scss +305 -0
- package/dist/components/switch/QSwitch.svelte +115 -0
- package/dist/components/switch/QSwitch.svelte.d.ts +14 -0
- package/dist/components/switch/docs.d.ts +2 -0
- package/dist/components/switch/docs.js +17 -0
- package/dist/components/switch/docs.props.d.ts +3 -0
- package/dist/components/switch/docs.props.js +119 -0
- package/dist/components/switch/props.d.ts +53 -0
- package/dist/components/switch/props.js +1 -0
- package/dist/components/table/QTable.svelte +133 -97
- package/dist/components/table/QTable.svelte.d.ts +4 -19
- package/dist/components/table/docs.d.ts +2 -2
- package/dist/components/table/docs.js +3 -3
- package/dist/components/table/docs.props.d.ts +3 -8
- package/dist/components/table/docs.props.js +67 -15
- package/dist/components/table/index.scss +3 -1
- package/dist/components/table/props.d.ts +14 -3
- package/dist/components/tabs/QTab.scss +71 -0
- package/dist/components/tabs/QTab.svelte +101 -88
- package/dist/components/tabs/QTab.svelte.d.ts +4 -16
- package/dist/components/tabs/QTabs.scss +53 -0
- package/dist/components/tabs/QTabs.svelte +163 -46
- package/dist/components/tabs/QTabs.svelte.d.ts +9 -13
- package/dist/components/tabs/docs.d.ts +3 -2
- package/dist/components/tabs/docs.js +13 -3
- package/dist/components/tabs/docs.props.d.ts +5 -16
- package/dist/components/tabs/docs.props.js +64 -30
- package/dist/components/tabs/index.scss +36 -24
- package/dist/components/tabs/props.d.ts +38 -9
- package/dist/components/tabs/props.js +1 -13
- package/dist/components/toolbar/{index.scss → QToolbar.scss} +10 -16
- package/dist/components/toolbar/QToolbar.svelte +26 -21
- package/dist/components/toolbar/QToolbar.svelte.d.ts +4 -15
- package/dist/components/toolbar/QToolbarTitle.svelte +10 -7
- package/dist/components/toolbar/QToolbarTitle.svelte.d.ts +4 -12
- package/dist/components/toolbar/docs.d.ts +3 -2
- package/dist/components/toolbar/docs.js +13 -3
- package/dist/components/toolbar/docs.props.d.ts +5 -16
- package/dist/components/toolbar/docs.props.js +55 -15
- package/dist/components/toolbar/props.d.ts +19 -9
- package/dist/components/tooltip/QTooltip.scss +40 -0
- package/dist/components/tooltip/QTooltip.svelte +200 -10
- package/dist/components/tooltip/QTooltip.svelte.d.ts +17 -18
- package/dist/components/tooltip/QTooltipBase.svelte +86 -0
- package/dist/components/tooltip/QTooltipBase.svelte.d.ts +14 -0
- package/dist/components/tooltip/docs.d.ts +2 -2
- package/dist/components/tooltip/docs.js +3 -2
- package/dist/components/tooltip/docs.props.d.ts +3 -8
- package/dist/components/tooltip/docs.props.js +69 -10
- package/dist/components/tooltip/props.d.ts +36 -4
- package/dist/components/tooltip/props.js +1 -6
- package/dist/composables/index.d.ts +3 -0
- package/dist/composables/index.js +3 -1
- package/dist/composables/{use-align.d.ts → useAlign.d.ts} +1 -1
- package/dist/composables/{use-align.js → useAlign.js} +1 -1
- package/dist/composables/{use-router-link.d.ts → useRouterLink.d.ts} +3 -3
- package/dist/composables/{use-router-link.js → useRouterLink.js} +4 -4
- package/dist/composables/useSize.d.ts +10 -0
- package/dist/composables/useSize.js +37 -0
- package/dist/css/_components.scss +31 -0
- package/dist/css/_disabled.scss +18 -0
- package/dist/css/{ripple.scss → _ripple.scss} +10 -3
- package/dist/css/_variables.scss +73 -0
- package/dist/css/classes/_design.scss +57 -0
- package/dist/css/{flex.scss → classes/_flex.scss} +23 -2
- package/dist/css/classes/_grid.scss +35 -0
- package/dist/css/classes/_index.scss +7 -0
- package/dist/css/classes/_overflow.scss +7 -0
- package/dist/css/classes/_position.scss +7 -0
- package/dist/css/classes/_select.scss +6 -0
- package/dist/css/classes/_spaces.scss +23 -0
- package/dist/css/fonts.scss +18 -4
- package/dist/css/index.css +1 -1
- package/dist/css/index.scss +16 -92
- package/dist/css/mixins/_design.scss +64 -0
- package/dist/css/mixins/_field.scss +64 -0
- package/dist/css/mixins/_image.scss +64 -0
- package/dist/css/mixins/_index.scss +10 -0
- package/dist/css/mixins/_layout.scss +20 -0
- package/dist/css/mixins/{menu.scss → _menu.scss} +4 -2
- package/dist/css/mixins/{selection.scss → _selection.scss} +10 -70
- package/dist/css/mixins/_spaces.scss +36 -0
- package/dist/css/mixins/_toolbar.scss +7 -0
- package/dist/css/mixins/_typography.scss +7 -0
- package/dist/css/shared/q-field.scss +348 -0
- package/dist/css/theme/_color-classes.scss +332 -0
- package/dist/css/theme/_colors.scss +205 -0
- package/dist/css/theme/_css-variables.scss +5 -0
- package/dist/css/theme/_index.scss +12 -0
- package/dist/css/theme/_page.scss +17 -0
- package/dist/css/theme/{palette.scss → _palette.scss} +27 -5
- package/dist/css/theme/{reset.scss → _reset.scss} +11 -2
- package/dist/css/theme/_typography-variables.scss +107 -0
- package/dist/global.d.ts +1 -1
- package/dist/helpers/clickOutside.d.ts +2 -2
- package/dist/helpers/clickOutside.js +5 -4
- package/dist/helpers/index.d.ts +2 -1
- package/dist/helpers/index.js +2 -1
- package/dist/helpers/pageTitle.d.ts +1 -0
- package/dist/helpers/pageTitle.js +3 -0
- package/dist/helpers/ripple.d.ts +1 -0
- package/dist/helpers/ripple.js +31 -16
- package/dist/helpers/version.d.ts +1 -1
- package/dist/helpers/version.js +1 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +4 -1
- package/dist/stores/index.d.ts +0 -0
- package/dist/stores/index.js +1 -0
- package/dist/utils/clipboard.d.ts +1 -1
- package/dist/utils/clipboard.js +3 -4
- package/dist/utils/colors.d.ts +69 -0
- package/dist/utils/colors.js +141 -15
- package/dist/utils/context.d.ts +33 -0
- package/dist/utils/context.js +33 -0
- package/dist/utils/dom.d.ts +3 -0
- package/dist/utils/dom.js +14 -4
- package/dist/utils/events.d.ts +24 -0
- package/dist/utils/events.js +24 -0
- package/dist/utils/index.d.ts +11 -0
- package/dist/utils/index.js +11 -1
- package/dist/utils/number.d.ts +2 -0
- package/dist/utils/number.js +9 -0
- package/dist/utils/props.d.ts +4 -4
- package/dist/utils/props.js +8 -6
- package/dist/utils/router.d.ts +16 -0
- package/dist/utils/router.js +20 -0
- package/dist/utils/string.d.ts +2 -0
- package/dist/utils/string.js +12 -1
- package/dist/utils/types.d.ts +12 -18
- package/dist/utils/types.js +0 -3
- package/dist/utils/types.json +31 -1
- package/package.json +44 -39
- package/dist/components/breadcrumbs/index.scss +0 -20
- package/dist/components/button/index.scss +0 -98
- package/dist/components/card/index.scss +0 -56
- package/dist/components/chip/index.scss +0 -86
- package/dist/components/drawer/index.scss +0 -59
- package/dist/components/footer/index.scss +0 -28
- package/dist/components/layout/index.scss +0 -387
- package/dist/components/list/index.scss +0 -121
- package/dist/components/progress/index.scss +0 -65
- package/dist/components/railbar/index.scss +0 -39
- package/dist/components/toggle/QToggle.svelte +0 -35
- package/dist/components/toggle/QToggle.svelte.d.ts +0 -23
- package/dist/components/toggle/docs.d.ts +0 -2
- package/dist/components/toggle/docs.js +0 -47
- package/dist/components/toggle/docs.props.d.ts +0 -8
- package/dist/components/toggle/docs.props.js +0 -42
- package/dist/components/toggle/index.scss +0 -31
- package/dist/components/toggle/props.d.ts +0 -9
- package/dist/components/toggle/props.js +0 -9
- package/dist/components/tooltip/index.scss +0 -82
- package/dist/composables/use-index.d.ts +0 -2
- package/dist/composables/use-index.js +0 -17
- package/dist/composables/use-size.d.ts +0 -9
- package/dist/composables/use-size.js +0 -25
- package/dist/css/grid.scss +0 -50
- package/dist/css/mixins/field.scss +0 -432
- package/dist/css/mixins.scss +0 -136
- package/dist/css/states.scss +0 -75
- package/dist/css/theme/bridge.scss +0 -15
- package/dist/css/theme/colors.module.scss +0 -180
- package/dist/css/theme/page.scss +0 -16
- package/dist/css/theme/theme.dark.scss +0 -37
- package/dist/css/theme/theme.light.scss +0 -37
- package/dist/css/theme/theme.scss +0 -11
- package/dist/css/theme/tokens.scss +0 -266
- package/dist/css/variables-sass.scss +0 -16
- package/dist/helpers/activationHandler.d.ts +0 -9
- package/dist/helpers/activationHandler.js +0 -23
- package/dist/stores/QTheme.d.ts +0 -42
- package/dist/stores/QTheme.js +0 -53
- package/dist/stores/Quaff.d.ts +0 -32
- package/dist/stores/Quaff.js +0 -53
- package/dist/utils/fields.d.ts +0 -1
- package/dist/utils/fields.js +0 -14
- package/dist/utils/watchable.d.ts +0 -3
- package/dist/utils/watchable.js +0 -22
- /package/dist/css/mixins/{table.scss → _table.scss} +0 -0
- /package/dist/css/theme/{elevate.scss → _elevate.scss} +0 -0
- /package/dist/css/theme/{typography.module.scss → _typography-classes.scss} +0 -0
- /package/dist/css/theme/{typography.scss → _typography.scss} +0 -0
|
@@ -1,48 +1,91 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import
|
|
3
|
-
import "
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
let
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { QBtn, Quaff } from "../..";
|
|
3
|
+
import { copy } from "../../utils";
|
|
4
|
+
import type { QCodeBlockProps } from "./props";
|
|
5
|
+
|
|
6
|
+
let {
|
|
7
|
+
language,
|
|
8
|
+
lightTheme = "github-light-default",
|
|
9
|
+
darkTheme = "github-dark-default",
|
|
10
|
+
code = "/* No code found */",
|
|
11
|
+
title,
|
|
12
|
+
copiable,
|
|
13
|
+
...props
|
|
14
|
+
}: QCodeBlockProps = $props();
|
|
15
|
+
|
|
16
|
+
let btnContent = $state("Copy");
|
|
17
|
+
let btnColor = $state("primary");
|
|
18
|
+
|
|
19
|
+
let html = $state("");
|
|
20
|
+
|
|
21
|
+
$effect(() => {
|
|
22
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-expressions
|
|
23
|
+
Quaff.darkMode.isActive;
|
|
24
|
+
|
|
25
|
+
// This is required to have the html updated when the code changes
|
|
26
|
+
getHtml(code);
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
function setBtn(type: "base" | "error" | "success") {
|
|
30
|
+
switch (type) {
|
|
31
|
+
case "error":
|
|
32
|
+
btnContent = "Error while copying...";
|
|
33
|
+
btnColor = "error";
|
|
34
|
+
break;
|
|
35
|
+
case "success":
|
|
36
|
+
btnContent = "Copied!";
|
|
37
|
+
btnColor = "green";
|
|
38
|
+
break;
|
|
39
|
+
default:
|
|
40
|
+
btnContent = "Copy";
|
|
41
|
+
btnColor = "primary";
|
|
42
|
+
break;
|
|
16
43
|
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
async function copyCode() {
|
|
47
|
+
await copy(code).catch(() => {
|
|
48
|
+
setBtn("error");
|
|
49
|
+
setTimeout(() => setBtn("base"), 3000);
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
setBtn("success");
|
|
26
53
|
setTimeout(() => {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
54
|
+
setBtn("base");
|
|
55
|
+
}, 3000);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
async function getHtml(code: string) {
|
|
59
|
+
try {
|
|
60
|
+
const { codeToHtml } = await import("shiki");
|
|
61
|
+
|
|
62
|
+
html = await codeToHtml(code, {
|
|
63
|
+
lang: language,
|
|
64
|
+
theme: Quaff.darkMode.isActive ? darkTheme : lightTheme,
|
|
65
|
+
});
|
|
66
|
+
} catch {
|
|
67
|
+
console.error("Error while loading shiki, make sure it is installed");
|
|
68
|
+
html = `<pre>${code}</pre>`;
|
|
69
|
+
}
|
|
30
70
|
}
|
|
31
|
-
}
|
|
32
71
|
</script>
|
|
33
72
|
|
|
34
|
-
<div class="q-code-block">
|
|
73
|
+
<div {...props} class="q-code-block" data-quaff>
|
|
35
74
|
{#if copiable}
|
|
36
|
-
<div
|
|
75
|
+
<div
|
|
76
|
+
class="flex justify-between {title
|
|
77
|
+
? 'items-center'
|
|
78
|
+
: 'justify-end'} q-pb-sm"
|
|
79
|
+
>
|
|
37
80
|
{#if title}
|
|
38
81
|
<h4 class="q-ma-none q-pr-lg">{title}</h4>
|
|
39
82
|
{/if}
|
|
40
83
|
<QBtn
|
|
41
|
-
class="{btnColor}-
|
|
84
|
+
class="border-{btnColor} text-{btnColor}"
|
|
42
85
|
size="sm"
|
|
43
86
|
icon="content_copy"
|
|
44
|
-
|
|
45
|
-
|
|
87
|
+
variant="outlined"
|
|
88
|
+
onclick={copyCode}
|
|
46
89
|
>
|
|
47
90
|
{btnContent}
|
|
48
91
|
</QBtn>
|
|
@@ -50,21 +93,24 @@ async function copyCode() {
|
|
|
50
93
|
{:else if title}
|
|
51
94
|
<h4>{title}</h4>
|
|
52
95
|
{/if}
|
|
53
|
-
|
|
96
|
+
{#await html}
|
|
97
|
+
<!-- waiting -->
|
|
98
|
+
{:then htmlContent}
|
|
99
|
+
{@html htmlContent}
|
|
100
|
+
{:catch error}
|
|
101
|
+
<pre>An error occurred: {error}</pre>
|
|
102
|
+
<!-- error -->
|
|
103
|
+
{/await}
|
|
54
104
|
</div>
|
|
55
105
|
|
|
56
106
|
<style>
|
|
57
107
|
.q-code-block {
|
|
58
|
-
border-radius:
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
pre {
|
|
62
|
-
max-height: 400px;
|
|
63
|
-
height: 100%;
|
|
64
|
-
margin: 0;
|
|
65
|
-
}
|
|
108
|
+
border-radius: inherit;
|
|
66
109
|
|
|
67
|
-
|
|
68
|
-
|
|
110
|
+
:global(pre) {
|
|
111
|
+
text-align: left;
|
|
112
|
+
padding: 1rem;
|
|
113
|
+
overflow: auto;
|
|
114
|
+
}
|
|
69
115
|
}
|
|
70
116
|
</style>
|
|
@@ -1,13 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "svelte-highlight/styles/material.css";
|
|
3
|
-
import type { QCodeBlockProps } from "./props";
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
4
2
|
declare const __propDef: {
|
|
5
|
-
props:
|
|
6
|
-
language: QCodeBlockProps["language"];
|
|
7
|
-
code?: QCodeBlockProps["code"];
|
|
8
|
-
title?: QCodeBlockProps["title"];
|
|
9
|
-
copiable?: QCodeBlockProps["copiable"];
|
|
10
|
-
};
|
|
3
|
+
props: Record<string, never>;
|
|
11
4
|
events: {
|
|
12
5
|
[evt: string]: CustomEvent<any>;
|
|
13
6
|
};
|
|
@@ -17,5 +10,5 @@ type QCodeBlockProps_ = typeof __propDef.props;
|
|
|
17
10
|
export { QCodeBlockProps_ as QCodeBlockProps };
|
|
18
11
|
export type QCodeBlockEvents = typeof __propDef.events;
|
|
19
12
|
export type QCodeBlockSlots = typeof __propDef.slots;
|
|
20
|
-
export default class QCodeBlock extends
|
|
13
|
+
export default class QCodeBlock extends SvelteComponentTyped<QCodeBlockProps_, QCodeBlockEvents, QCodeBlockSlots> {
|
|
21
14
|
}
|
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
optional: boolean;
|
|
5
|
-
clickableType: boolean;
|
|
6
|
-
description: string;
|
|
7
|
-
default: string;
|
|
8
|
-
}[];
|
|
1
|
+
import { ParsedProp, ParsedSnippet } from "../../../../docgen/props/parseInterface";
|
|
2
|
+
export declare const QCodeBlockDocsProps: ParsedProp[];
|
|
3
|
+
export declare const QCodeBlockDocsSnippets: ParsedSnippet[];
|
|
@@ -1,34 +1,83 @@
|
|
|
1
|
+
// AUTO GENERATED FILE - DO NOT MODIFY OR DELETE
|
|
2
|
+
// @quaffHash f885caf4da487ca619a0400e7d09d636
|
|
1
3
|
export const QCodeBlockDocsProps = [
|
|
2
4
|
{
|
|
3
|
-
|
|
4
|
-
type: "string",
|
|
5
|
+
isArray: false,
|
|
5
6
|
optional: false,
|
|
6
|
-
|
|
7
|
+
isSnippet: false,
|
|
8
|
+
name: "language",
|
|
9
|
+
type: [
|
|
10
|
+
{
|
|
11
|
+
name: "BundledLanguage",
|
|
12
|
+
isClickable: true,
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
name: "SpecialLanguage",
|
|
16
|
+
isClickable: true,
|
|
17
|
+
},
|
|
18
|
+
],
|
|
7
19
|
description: "Language to use for highlighting.",
|
|
8
20
|
default: "",
|
|
9
21
|
},
|
|
10
22
|
{
|
|
11
|
-
|
|
12
|
-
|
|
23
|
+
isArray: false,
|
|
24
|
+
optional: true,
|
|
25
|
+
isSnippet: false,
|
|
26
|
+
name: "lightTheme",
|
|
27
|
+
type: {
|
|
28
|
+
name: "BundledTheme",
|
|
29
|
+
isClickable: true,
|
|
30
|
+
},
|
|
31
|
+
description: "Theme to use for highlighting for light mode.",
|
|
32
|
+
default: "",
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
isArray: false,
|
|
36
|
+
optional: true,
|
|
37
|
+
isSnippet: false,
|
|
38
|
+
name: "darkTheme",
|
|
39
|
+
type: {
|
|
40
|
+
name: "BundledTheme",
|
|
41
|
+
isClickable: true,
|
|
42
|
+
},
|
|
43
|
+
description: "Theme to use for highlighting for dark mode.",
|
|
44
|
+
default: "",
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
isArray: false,
|
|
13
48
|
optional: true,
|
|
14
|
-
|
|
49
|
+
isSnippet: false,
|
|
50
|
+
name: "code",
|
|
51
|
+
type: {
|
|
52
|
+
name: "string",
|
|
53
|
+
isClickable: false,
|
|
54
|
+
},
|
|
15
55
|
description: "Code to highlight.",
|
|
16
56
|
default: "",
|
|
17
57
|
},
|
|
18
58
|
{
|
|
19
|
-
|
|
20
|
-
type: "string",
|
|
59
|
+
isArray: false,
|
|
21
60
|
optional: true,
|
|
22
|
-
|
|
61
|
+
isSnippet: false,
|
|
62
|
+
name: "title",
|
|
63
|
+
type: {
|
|
64
|
+
name: "string",
|
|
65
|
+
isClickable: false,
|
|
66
|
+
},
|
|
23
67
|
description: "Title to display above the code.",
|
|
24
68
|
default: "undefined",
|
|
25
69
|
},
|
|
26
70
|
{
|
|
27
|
-
|
|
28
|
-
type: "boolean",
|
|
71
|
+
isArray: false,
|
|
29
72
|
optional: true,
|
|
30
|
-
|
|
73
|
+
isSnippet: false,
|
|
74
|
+
name: "copiable",
|
|
75
|
+
type: {
|
|
76
|
+
name: "boolean",
|
|
77
|
+
isClickable: false,
|
|
78
|
+
},
|
|
31
79
|
description: "Wether the code should be copiable or not.",
|
|
32
80
|
default: "false",
|
|
33
81
|
},
|
|
34
82
|
];
|
|
83
|
+
export const QCodeBlockDocsSnippets = [];
|
|
@@ -1,8 +1,18 @@
|
|
|
1
|
-
|
|
1
|
+
import type { HTMLAttributes } from "svelte/elements";
|
|
2
|
+
import type { SpecialLanguage, BundledLanguage, BundledTheme } from "shiki";
|
|
3
|
+
export interface QCodeBlockProps extends HTMLAttributes<HTMLDivElement> {
|
|
2
4
|
/**
|
|
3
5
|
* Language to use for highlighting.
|
|
4
6
|
*/
|
|
5
|
-
language:
|
|
7
|
+
language: BundledLanguage | SpecialLanguage;
|
|
8
|
+
/**
|
|
9
|
+
* Theme to use for highlighting for light mode.
|
|
10
|
+
*/
|
|
11
|
+
lightTheme?: BundledTheme;
|
|
12
|
+
/**
|
|
13
|
+
* Theme to use for highlighting for dark mode.
|
|
14
|
+
*/
|
|
15
|
+
darkTheme?: BundledTheme;
|
|
6
16
|
/**
|
|
7
17
|
* Code to highlight.
|
|
8
18
|
*/
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
@use "$css/mixins";
|
|
2
|
+
@use "$css/variables";
|
|
3
|
+
|
|
1
4
|
.q-dialog {
|
|
2
5
|
display: block;
|
|
3
6
|
border: none;
|
|
@@ -17,19 +20,14 @@
|
|
|
17
20
|
overflow-x: hidden;
|
|
18
21
|
overflow-y: auto;
|
|
19
22
|
transition:
|
|
20
|
-
|
|
23
|
+
variables.$speed3 all,
|
|
21
24
|
0s background-color;
|
|
22
25
|
transform: translate(-50%, -4rem);
|
|
26
|
+
transform-origin: center left;
|
|
23
27
|
animation-timing-function: cubic-bezier(0.25, 0.8, 0.25, 1);
|
|
24
28
|
|
|
25
|
-
&:is(&--active, [open]) {
|
|
26
|
-
opacity: 1;
|
|
27
|
-
visibility: visible;
|
|
28
|
-
transform: translate(-50%, 0);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
29
|
&::backdrop {
|
|
32
|
-
|
|
30
|
+
pointer-events: none;
|
|
33
31
|
}
|
|
34
32
|
|
|
35
33
|
&:not(&--left, &--right, &--top, &--bottom) {
|
|
@@ -51,13 +49,13 @@
|
|
|
51
49
|
height: 75%;
|
|
52
50
|
}
|
|
53
51
|
|
|
54
|
-
&:is(&--active, [open]) {
|
|
52
|
+
&:is(&--active, [open], .active) {
|
|
55
53
|
opacity: 1;
|
|
56
54
|
visibility: visible;
|
|
57
55
|
transform: translate(-50%, 0);
|
|
58
56
|
}
|
|
59
57
|
|
|
60
|
-
&:is(&--active, [open]):is(&--left, &--right, &--top, &--bottom, &--
|
|
58
|
+
&:is(&--active, [open]):is(&--left, &--right, &--top, &--bottom, &--fullscreen) {
|
|
61
59
|
transform: translate(0, 0);
|
|
62
60
|
}
|
|
63
61
|
|
|
@@ -111,7 +109,7 @@
|
|
|
111
109
|
transform: translateY(100%);
|
|
112
110
|
}
|
|
113
111
|
|
|
114
|
-
&--
|
|
112
|
+
&--fullscreen {
|
|
115
113
|
top: 0;
|
|
116
114
|
left: 0;
|
|
117
115
|
right: auto;
|
|
@@ -153,10 +151,10 @@
|
|
|
153
151
|
|
|
154
152
|
&--modal::backdrop {
|
|
155
153
|
display: block;
|
|
156
|
-
background-color:
|
|
154
|
+
background-color: mixins.with-alpha(var(--shadow), 50%);
|
|
157
155
|
}
|
|
158
156
|
|
|
159
|
-
|
|
157
|
+
&--animating {
|
|
160
158
|
animation: shake 0.15s;
|
|
161
159
|
}
|
|
162
160
|
}
|
|
@@ -166,7 +164,7 @@
|
|
|
166
164
|
scale: 1;
|
|
167
165
|
}
|
|
168
166
|
50% {
|
|
169
|
-
scale: 1.
|
|
167
|
+
scale: 1.01;
|
|
170
168
|
}
|
|
171
169
|
100% {
|
|
172
170
|
scale: 1;
|
|
@@ -1,94 +1,101 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { QDialogProps } from "./props";
|
|
3
|
+
|
|
4
|
+
let {
|
|
5
|
+
value = $bindable(false),
|
|
6
|
+
position = "default",
|
|
7
|
+
modal = false,
|
|
8
|
+
fullscreen = false,
|
|
9
|
+
persistent = false,
|
|
10
|
+
children,
|
|
11
|
+
...props
|
|
12
|
+
}: QDialogProps = $props();
|
|
13
|
+
|
|
14
|
+
let dialogEl = $state<HTMLDialogElement>();
|
|
15
|
+
|
|
16
|
+
const canHide = $derived(value && !persistent);
|
|
17
|
+
|
|
18
|
+
$effect(() => {
|
|
19
|
+
if (value) {
|
|
20
|
+
dialogEl?.[modal ? "showModal" : "show"]();
|
|
21
|
+
|
|
22
|
+
setTimeout(() => {
|
|
23
|
+
window.addEventListener("click", tryCancel);
|
|
24
|
+
}, 150);
|
|
25
|
+
} else {
|
|
26
|
+
dialogEl?.close();
|
|
27
|
+
|
|
28
|
+
window.removeEventListener("click", tryCancel);
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
export function hide() {
|
|
33
|
+
if (dialogEl?.open) {
|
|
34
|
+
value = false;
|
|
24
35
|
}
|
|
25
|
-
);
|
|
26
|
-
export function hide() {
|
|
27
|
-
if (dialogElement && dialogElement.open) {
|
|
28
|
-
dialogElement.close();
|
|
29
|
-
opened = false;
|
|
30
|
-
setTimeout(() => {
|
|
31
|
-
dialogElement.style.display = "none";
|
|
32
|
-
}, 250);
|
|
33
36
|
}
|
|
34
|
-
|
|
35
|
-
export function show() {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
dialogElement.style.display = "block";
|
|
37
|
+
|
|
38
|
+
export function show() {
|
|
39
|
+
if (!dialogEl?.open) {
|
|
40
|
+
value = true;
|
|
41
|
+
}
|
|
40
42
|
}
|
|
41
|
-
|
|
42
|
-
export function toggle(
|
|
43
|
-
|
|
44
|
-
opened = !opened;
|
|
45
|
-
if (dialogElement.open) {
|
|
43
|
+
|
|
44
|
+
export function toggle() {
|
|
45
|
+
if (dialogEl?.open) {
|
|
46
46
|
hide();
|
|
47
47
|
} else {
|
|
48
48
|
show();
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
51
|
+
|
|
52
|
+
function addAnimation() {
|
|
53
|
+
if (persistent && value) {
|
|
54
|
+
dialogEl?.classList.add("q-dialog--animating");
|
|
55
|
+
|
|
56
|
+
setTimeout(() => {
|
|
57
|
+
dialogEl?.classList.remove("q-dialog--animating");
|
|
58
|
+
}, 150);
|
|
59
|
+
}
|
|
59
60
|
}
|
|
60
|
-
|
|
61
|
-
function
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
e.
|
|
61
|
+
|
|
62
|
+
function handleClickInside(e: MouseEvent) {
|
|
63
|
+
e.stopPropagation();
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function onkeydown(e: KeyboardEvent) {
|
|
67
|
+
if (e.key === "Escape") {
|
|
68
|
+
tryCancel(e);
|
|
69
|
+
}
|
|
67
70
|
}
|
|
68
|
-
|
|
69
|
-
function
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
71
|
+
|
|
72
|
+
function tryCancel(e: Event) {
|
|
73
|
+
if (canHide) {
|
|
74
|
+
hide();
|
|
75
|
+
} else {
|
|
76
|
+
addAnimation();
|
|
77
|
+
e.preventDefault();
|
|
78
|
+
}
|
|
74
79
|
}
|
|
75
|
-
}
|
|
76
80
|
</script>
|
|
77
81
|
|
|
78
|
-
{#if noBtn === false}
|
|
79
|
-
<QBtn {...btnAttrs} on:click={toggle} on:click={(event) => emit("btnClick", event)}>
|
|
80
|
-
<slot name="button">
|
|
81
|
-
{btnContent || ""}
|
|
82
|
-
</slot>
|
|
83
|
-
</QBtn>
|
|
84
|
-
{/if}
|
|
85
|
-
|
|
86
82
|
<dialog
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
{
|
|
90
|
-
|
|
91
|
-
|
|
83
|
+
bind:this={dialogEl}
|
|
84
|
+
{...props}
|
|
85
|
+
class={[
|
|
86
|
+
"q-dialog",
|
|
87
|
+
props.class,
|
|
88
|
+
value && "q-dialog--active",
|
|
89
|
+
fullscreen && "q-dialog--fullscreen",
|
|
90
|
+
modal && "q-dialog--modal",
|
|
91
|
+
["top", "right", "bottom", "left"].includes(position) &&
|
|
92
|
+
`q-dialog--${position}`,
|
|
93
|
+
]}
|
|
94
|
+
onclick={handleClickInside}
|
|
95
|
+
oncancel={tryCancel}
|
|
96
|
+
{onkeydown}
|
|
97
|
+
aria-hidden={!value || undefined}
|
|
98
|
+
data-quaff
|
|
92
99
|
>
|
|
93
|
-
|
|
100
|
+
{@render children?.()}
|
|
94
101
|
</dialog>
|
|
@@ -1,36 +1,21 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type { QDialogProps } from "./props";
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
3
2
|
declare const __propDef: {
|
|
4
3
|
props: {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
btnAttrs?: QDialogProps["btnAttrs"];
|
|
9
|
-
position?: QDialogProps["position"];
|
|
10
|
-
modal?: QDialogProps["modal"];
|
|
11
|
-
fullscreen?: QDialogProps["fullscreen"];
|
|
12
|
-
persistent?: QDialogProps["persistent"];
|
|
13
|
-
class?: string | undefined;
|
|
14
|
-
hide?: (() => void) | undefined;
|
|
15
|
-
show?: (() => void) | undefined;
|
|
16
|
-
toggle?: ((e: MouseEvent) => void) | undefined;
|
|
4
|
+
hide?: () => void;
|
|
5
|
+
show?: () => void;
|
|
6
|
+
toggle?: () => void;
|
|
17
7
|
};
|
|
18
8
|
events: {
|
|
19
|
-
btnClick: CustomEvent<any>;
|
|
20
|
-
} & {
|
|
21
9
|
[evt: string]: CustomEvent<any>;
|
|
22
10
|
};
|
|
23
|
-
slots: {
|
|
24
|
-
button: {};
|
|
25
|
-
default: {};
|
|
26
|
-
};
|
|
11
|
+
slots: {};
|
|
27
12
|
};
|
|
28
13
|
type QDialogProps_ = typeof __propDef.props;
|
|
29
14
|
export { QDialogProps_ as QDialogProps };
|
|
30
15
|
export type QDialogEvents = typeof __propDef.events;
|
|
31
16
|
export type QDialogSlots = typeof __propDef.slots;
|
|
32
|
-
export default class QDialog extends
|
|
33
|
-
get hide():
|
|
34
|
-
get show():
|
|
35
|
-
get toggle():
|
|
17
|
+
export default class QDialog extends SvelteComponentTyped<QDialogProps_, QDialogEvents, QDialogSlots> {
|
|
18
|
+
get hide(): () => void;
|
|
19
|
+
get show(): () => void;
|
|
20
|
+
get toggle(): () => void;
|
|
36
21
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { QComponentDocs } from "../../utils
|
|
2
|
-
export declare
|
|
1
|
+
import type { QComponentDocs } from "../../utils";
|
|
2
|
+
export declare const QDialogDocs: QComponentDocs;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { QDialogDocsProps } from "./docs.props";
|
|
2
|
-
export
|
|
1
|
+
import { QDialogDocsProps, QDialogDocsSnippets } from "./docs.props";
|
|
2
|
+
export const QDialogDocs = {
|
|
3
3
|
name: "QDialog",
|
|
4
4
|
description: "Dialogs provide important prompts in a user flow.",
|
|
5
5
|
docs: {
|
|
6
6
|
props: QDialogDocsProps,
|
|
7
|
-
|
|
7
|
+
snippets: QDialogDocsSnippets,
|
|
8
8
|
methods: [],
|
|
9
9
|
events: [],
|
|
10
10
|
},
|
|
@@ -1,16 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
optional: boolean;
|
|
5
|
-
clickableType: boolean;
|
|
6
|
-
description: string;
|
|
7
|
-
default: string;
|
|
8
|
-
}[];
|
|
9
|
-
export declare const QDialogDocsProps: {
|
|
10
|
-
name: string;
|
|
11
|
-
type: string;
|
|
12
|
-
optional: boolean;
|
|
13
|
-
clickableType: boolean;
|
|
14
|
-
description: string;
|
|
15
|
-
default: string;
|
|
16
|
-
}[];
|
|
1
|
+
import { ParsedProp, ParsedSnippet } from "../../../../docgen/props/parseInterface";
|
|
2
|
+
export declare const QDialogDocsProps: ParsedProp[];
|
|
3
|
+
export declare const QDialogDocsSnippets: ParsedSnippet[];
|