@propelinc/citrus-ui 0.3.1 → 0.3.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/dist/citrus-ui.common.js +128 -116
- package/dist/citrus-ui.common.js.map +1 -1
- package/dist/citrus-ui.css +1 -1
- package/dist/citrus-ui.umd.js +128 -116
- package/dist/citrus-ui.umd.js.map +1 -1
- package/dist/citrus-ui.umd.min.js +4 -4
- package/dist/citrus-ui.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/CButton.vue +4 -0
- package/src/components/CCard.vue +4 -0
- package/src/components/CModal.vue +3 -1
- package/src/components/helpers/FormField.vue +7 -1
- package/src/index.d.ts +1 -0
- package/src/index.ts +2 -0
- package/src/styles/form-fields.less +1 -0
package/package.json
CHANGED
|
@@ -24,6 +24,8 @@
|
|
|
24
24
|
:to="to"
|
|
25
25
|
:text="tertiary"
|
|
26
26
|
:disabled="disabled"
|
|
27
|
+
:href="href"
|
|
28
|
+
:target="target"
|
|
27
29
|
v-on="$listeners"
|
|
28
30
|
>
|
|
29
31
|
<div v-if="hasIcon" class="button__icon">
|
|
@@ -53,6 +55,8 @@ export default class CButton extends Vue {
|
|
|
53
55
|
@Prop({ type: Boolean, default: false }) secondary!: boolean;
|
|
54
56
|
@Prop({ type: Boolean, default: false }) tertiary!: boolean;
|
|
55
57
|
@Prop([Object, String]) to?: RawLocation;
|
|
58
|
+
@Prop(String) href?: string;
|
|
59
|
+
@Prop(String) target?: string;
|
|
56
60
|
|
|
57
61
|
get hasIcon(): boolean {
|
|
58
62
|
return !!(this.icon || this.$slots.icon || this.$scopedSlots.icon);
|
package/src/components/CCard.vue
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
</div>
|
|
22
22
|
</div>
|
|
23
23
|
</c-card>
|
|
24
|
-
<c-card v-else key="default" data-test="modal">
|
|
24
|
+
<c-card v-else key="default" :fluid="fluid" data-test="modal">
|
|
25
25
|
<template #header:title>
|
|
26
26
|
<span class="modal__header__title" data-test="modal-title">{{ title }}</span>
|
|
27
27
|
</template>
|
|
@@ -58,6 +58,8 @@ export default class CModal extends Vue {
|
|
|
58
58
|
|
|
59
59
|
@Prop({ type: Boolean, default: false }) value!: boolean;
|
|
60
60
|
@Prop(String) title?: string;
|
|
61
|
+
/** Removes padding from modal body */
|
|
62
|
+
@Prop({ type: Boolean, default: false }) fluid!: boolean;
|
|
61
63
|
/** Shows loading state + sets loading message if string */
|
|
62
64
|
@Prop([String, Boolean]) loading?: string | boolean;
|
|
63
65
|
/** Allows modal to be dismissed */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<fieldset :disabled="disabled">
|
|
2
|
+
<fieldset class="form-field" :disabled="disabled">
|
|
3
3
|
<label
|
|
4
4
|
v-if="label"
|
|
5
5
|
:for="fieldId"
|
|
@@ -29,6 +29,12 @@ export default class FormField extends Vue {
|
|
|
29
29
|
@import '~@/styles/variables.less';
|
|
30
30
|
@import '~@/styles/form-fields.less';
|
|
31
31
|
|
|
32
|
+
.form-field {
|
|
33
|
+
border: none;
|
|
34
|
+
margin: 0;
|
|
35
|
+
padding: 0;
|
|
36
|
+
}
|
|
37
|
+
|
|
32
38
|
.form-field__label {
|
|
33
39
|
font-weight: @font-weight-bold;
|
|
34
40
|
margin: 0 0 4px 2px;
|
package/src/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ export const CCard: Component;
|
|
|
11
11
|
export const CCheckbox: Component;
|
|
12
12
|
export const CIconButton: Component;
|
|
13
13
|
export const CListItem: Component;
|
|
14
|
+
export const CModal: Component;
|
|
14
15
|
export const CModalLoading: Component;
|
|
15
16
|
export const CSegmentedButton: Component;
|
|
16
17
|
export const CSegmentedButtonOption: Component;
|
package/src/index.ts
CHANGED
|
@@ -7,6 +7,7 @@ import _CCard from '@/components/CCard.vue';
|
|
|
7
7
|
import _CCheckbox from '@/components/CCheckbox.vue';
|
|
8
8
|
import _CIconButton from '@/components/CIconButton.vue';
|
|
9
9
|
import _CListItem from '@/components/CListItem.vue';
|
|
10
|
+
import _CModal from '@/components/CModal.vue';
|
|
10
11
|
import _CModalLoading from '@/components/CModalLoading.vue';
|
|
11
12
|
import _CSegmentedButton from '@/components/CSegmentedButton.vue';
|
|
12
13
|
import _CSegmentedButtonOption from '@/components/CSegmentedButtonOption.vue';
|
|
@@ -29,6 +30,7 @@ export const CCard = _CCard;
|
|
|
29
30
|
export const CCheckbox = _CCheckbox;
|
|
30
31
|
export const CIconButton = _CIconButton;
|
|
31
32
|
export const CListItem = _CListItem;
|
|
33
|
+
export const CModal = _CModal;
|
|
32
34
|
export const CModalLoading = _CModalLoading;
|
|
33
35
|
export const CSegmentedButton = _CSegmentedButton;
|
|
34
36
|
export const CSegmentedButtonOption = _CSegmentedButtonOption;
|