8000 refactor: move props and types to src folder · xuybin/coreui-vue@15e1c35 · GitHub
[go: up one dir, main page]

Skip to content

Commit 15e1c35

Browse files
committed
refactor: move props and types to src folder
1 parent f97d0dc commit 15e1c35

30 files changed

+59
-45
lines changed

packages/coreui-vue/src/components/accordion/CAccordionBody.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { defineComponent, h, inject, Ref } from 'vue'
2-
import { CCollapse } from './../collapse/CCollapse'
2+
import { CCollapse } from '../collapse/CCollapse'
33

44
const CAccordionBody = defineComponent({
55
name: 'CAccordionBody',

packages/coreui-vue/src/components/alert/CAlert.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import { defineComponent, h, ref, Transition, watch } from 'vue'
22

3-
import { Color } from '../props'
4-
import { CCloseButton } from '../close-button/CCloseButton'
3+
import { CCloseButton } from '../close-button'
4+
5+
import { Color } from '../../props'
56

67
export const CAlert = defineComponent({
78
name: 'CAlert',

packages/coreui-vue/src/components/avatar/CAvatar.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { defineComponent, h } from 'vue'
2-
import { Color, Shape, TextColor } from '../props'
2+
3+
import { Color, Shape, TextColor } from '../../props'
34

45
const CAvatar = defineComponent({
56
name: 'CAvatar',

packages/coreui-vue/src/components/badge/CBadge.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { defineComponent, h } from 'vue'
22

3-
import { Color, Shape, TextColor } from '../props'
3+
import { Color, Shape, TextColor } from '../../props'
44

55
const CBadge = defineComponent({
66
name: 'CBadge',

packages/coreui-vue/src/components/button/CButton.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { defineComponent, h } from 'vue'
2-
import { Color, Shape } from '../props'
2+
3+
import { Color, Shape } from '../../props'
34

45
export const CButton = defineComponent({
56
name: 'CButton',

packages/coreui-vue/src/components/callout/CCallout.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { defineComponent, h } from 'vue'
2-
import { Color } from '../props'
2+
3+
import { Color } from '../../props'
34

45
const CCallout = defineComponent({
56
name: 'CCallout',

packages/coreui-vue/src/components/card/CCard.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { defineComponent, h } from 'vue'
2-
import { Color, TextColor } from '../props'
2+
3+
import { Color, TextColor } from '../../props'
34

45
const CCard = defineComponent({
56
name: 'CCard',

packages/coreui-vue/src/components/dropdown/CDropdown.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import { defineComponent, h, ref, provide, watch, PropType } from 'vue'
22
import { createPopper, Placement } from '@popperjs/core'
33

4+
import { Triggers } from '../../types'
5+
46
const CDropdown = defineComponent({
57
name: 'CDropdown',
68
props: {
@@ -91,7 +93,7 @@ const CDropdown = defineComponent({
9193
* Sets which event handlers you’d like provided to your toggle prop. You can specify one trigger or an array of them.
9294
*/
9395
trigger: {
94-
type: [String, Array],
96+
type: String as PropType<Triggers>,
9597
default: 'click',
9698
},
9799
/**

packages/coreui-vue/src/components/dropdown/CDropdownToggle.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import { cloneVNode, defineComponent, h, inject, onMounted, PropType, Ref, ref } from 'vue'
2+
23
import { CButton } from '../button'
3-
import { Color, Shape } from '../props'
4-
import { Triggers } from '../Types'
4+
5+
import { Color, Shape } from '../../props'
6+
import { Triggers } from '../../types'
57

68
const CDropdownToggle = defineComponent({
79
name: 'CDropdownToggle',

packages/coreui-vue/src/components/list-group/CListGroupItem.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { defineComponent, h } from 'vue'
22

3-
import { Color } from '../props'
3+
import { Color } from '../../props'
44

55
const CListGroupItem = defineComponent({
66
name: 'CListGroupItem',

0 commit comments

Comments
 (0)
0