@farm-investimentos/front-mfe-components 8.7.1 → 9.1.1
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/front-mfe-components.common.js +2326 -2122
- package/dist/front-mfe-components.common.js.map +1 -1
- package/dist/front-mfe-components.css +1 -1
- package/dist/front-mfe-components.umd.js +2326 -2122
- package/dist/front-mfe-components.umd.js.map +1 -1
- package/dist/front-mfe-components.umd.min.js +1 -1
- package/dist/front-mfe-components.umd.min.js.map +1 -1
- package/package.json +2 -2
- package/src/components/Buttons/ConfirmButton/ConfirmButton.vue +1 -5
- package/src/components/Buttons/DangerButton/DangerButton.stories.js +7 -18
- package/src/components/Buttons/DangerButton/DangerButton.vue +2 -6
- package/src/components/Buttons/DefaultButton/DefaultButton.scss +11 -2
- package/src/components/Buttons/DefaultButton/DefaultButton.stories.js +11 -7
- package/src/components/Buttons/DefaultButton/DefaultButton.vue +15 -15
- package/src/components/Buttons/DefaultButton/__tests__/DefaultButton.spec.js +0 -4
- package/src/components/Buttons/ExportButton/ExportButton.stories.js +3 -6
- package/src/components/Buttons/ExportButton/ExportButton.vue +1 -7
- package/src/components/Buttons/ImportButton/ImportButton.scss +9 -0
- package/src/components/Buttons/ImportButton/ImportButton.stories.js +5 -9
- package/src/components/Buttons/ImportButton/ImportButton.vue +4 -15
- package/src/components/Buttons/MultiImportButton/MultiImportButton.stories.js +2 -5
- package/src/components/Buttons/MultiImportButton/MultiImportButton.vue +0 -2
- package/src/components/Buttons/RemoveButton/RemoveButton.scss +5 -0
- package/src/components/Buttons/RemoveButton/RemoveButton.stories.js +2 -4
- package/src/components/Buttons/RemoveButton/RemoveButton.vue +2 -12
- package/src/components/Buttons/ToggleButton/ToggleButton.stories.js +5 -12
- package/src/components/Buttons/ToggleButton/ToggleButton.vue +3 -9
- package/src/{examples/Card.stories.ts → components/Card/CardComposition.stories.ts} +2 -29
- package/src/components/CardContext/CardContext.stories.js +14 -26
- package/src/components/CardContext/CardContext.vue +5 -5
- package/src/components/Checkbox/Checkbox.scss +29 -0
- package/src/components/Checkbox/Checkbox.stories.js +49 -0
- package/src/components/Checkbox/Checkbox.vue +48 -0
- package/src/components/Checkbox/__tests__/Checkbox.spec.js +20 -0
- package/src/components/Checkbox/index.ts +4 -0
- package/src/components/Chip/Chip.stories.js +44 -3
- package/src/{examples → components/Chip}/Chip.stories.scss +0 -0
- package/src/components/Chip/Chip.vue +4 -9
- package/src/components/ChipInviteStatus/ChipInviteStatus.stories.js +9 -12
- package/src/components/Collapsible/Collapsible.stories.js +41 -11
- package/src/components/Collapsible/Collapsible.vue +1 -10
- package/src/components/DataTableEmptyWrapper/DataTableEmptyWrapper.stories.js +5 -11
- package/src/components/DataTableHeader/DataTableHeader.stories.js +1 -2
- package/src/components/DataTablePaginator/DataTablePaginator.stories.js +4 -4
- package/src/components/DataTablePaginator/__tests__/DataTablePaginator.spec.js +1 -1
- package/src/components/DatePicker/DatePicker.vue +8 -1
- package/src/components/DialogFooter/DialogFooter.stories.js +31 -3
- package/src/components/DialogHeader/DialogHeader.stories.js +33 -7
- package/src/components/FilePicker/FilePicker.stories.js +1 -6
- package/src/components/Icon/Icon.stories.js +2 -2
- package/src/components/IconBox/IconBox.scss +17 -5
- package/src/components/IconBox/IconBox.stories.js +65 -5
- package/src/components/IconBox/IconBox.vue +18 -6
- package/src/components/IdCaption/IdCaption.scss +36 -0
- package/src/components/IdCaption/IdCaption.stories.js +116 -0
- package/src/components/IdCaption/IdCaption.vue +63 -0
- package/src/components/IdCaption/__tests__/IdCaption.spec.js +14 -0
- package/src/components/IdCaption/index.ts +3 -0
- package/src/components/Label/Label.stories.js +3 -12
- package/src/{examples → components/Loader}/Loader.stories.ts +2 -11
- package/src/components/Logger/Logger.stories.js +36 -6
- package/src/components/Logger/LoggerItem/LoggerItem.stories.js +42 -4
- package/src/components/Logger/LoggerItem/LoggerItem.vue +0 -4
- package/src/components/Logos/OriginatorLogo/OriginatorLogo.stories.js +2 -3
- package/src/components/Logos/ProductLogo/ProductLogo.stories.js +2 -3
- package/src/components/MainFilter/MainFilter.stories.js +19 -10
- package/src/components/MainFilter/MainFilter.vue +2 -12
- package/src/components/ManagersList/ManagersList.stories.js +2 -6
- package/src/components/ManagersList/ManagersList.vue +5 -3
- package/src/components/ModalPromptUser/ModalPromptUser.stories.js +22 -30
- package/src/components/ModalPromptUser/ModalPromptUser.vue +0 -4
- package/src/components/MultipleFilePicker/MultipleFilePicker.stories.js +1 -10
- package/src/components/MultipleSelectShortener/MultipleSelectShortener.stories.js +2 -7
- package/src/components/ProgressBar/ProgressBar.stories.js +16 -11
- package/src/components/PromptUserToConfirm/PromptUserToConfirm.stories.js +18 -12
- package/src/components/PromptUserToConfirm/PromptUserToConfirm.vue +5 -3
- package/src/components/ResetTableRowSelection/ResetTableRowSelection.stories.js +1 -4
- package/src/components/SelectModalOptions/SelectModalOptions.stories.js +3 -8
- package/src/components/Stepper/StepperHeader/StepperHeader.stories.js +54 -3
- package/src/components/Stepper/StepperHeader/StepperHeader.vue +0 -4
- package/src/components/TableContextMenu/TableContextMenu.stories.js +20 -40
- package/src/components/TableContextMenu/TableContextMenu.vue +0 -2
- package/src/components/Tabs/Tabs.stories.js +2 -5
- package/src/components/Tabs/Tabs.vue +4 -3
- package/src/components/TextField/TextField.stories.js +25 -10
- package/src/components/Typography/BodyText/BodyText.stories.js +34 -6
- package/src/components/Typography/BodyText/BodyText.vue +0 -3
- package/src/components/Typography/Caption/Caption.stories.js +30 -7
- package/src/components/Typography/Caption/Caption.vue +0 -2
- package/src/components/Typography/Heading/Heading.stories.js +7 -6
- package/src/components/Typography/Heading/Heading.vue +0 -2
- package/src/components/Typography/OverlayText/OverlayText.stories.js +0 -1
- package/src/components/Typography/OverlayText/OverlayText.vue +0 -2
- package/src/components/Typography/Subtitle/Subtitle.stories.js +34 -6
- package/src/components/Typography/Subtitle/Subtitle.vue +0 -2
- package/src/configurations/_theme-colors-base.scss +8 -0
- package/src/configurations/_theme-colors-variations.scss +9 -0
- package/src/examples/Colors.stories.js +28 -0
- package/src/examples/Colors.stories.scss +15 -0
- package/src/examples/ConfirmDialog.stories.js +1 -9
- package/src/examples/Container/Basic.stories.js +2 -16
- package/src/examples/Form/Full.stories.js +1 -7
- package/src/examples/Modal.stories.js +1 -55
- package/src/examples/Table.stories.js +2 -11
- package/src/examples/inputs/Password.stories.js +1 -1
- package/src/examples/inputs/Select.stories.js +1 -1
- package/src/main.ts +3 -0
- package/src/stories/Introduction.stories.mdx +1 -1
- package/src/components/Loader/Loader.stories.js +0 -13
- package/src/examples/Chip.stories.js +0 -53
- package/src/examples/Collapsible.stories.js +0 -52
- package/src/examples/Dialog/DialogFooter.stories.js +0 -42
- package/src/examples/Dialog/DialogHeader.stories.js +0 -43
- package/src/examples/Form/Label.stories.js +0 -18
- package/src/examples/Form/TextField.stories.js +0 -47
- package/src/examples/IconBox.stories.js +0 -62
- package/src/examples/Logger/Logger.stories.js +0 -59
- package/src/examples/Logger/LoggerItem.stories.js +0 -81
- package/src/examples/MainFilter.stories.js +0 -29
- package/src/examples/ProgressBar.stories.js +0 -71
- package/src/examples/Stepper/StepperHeader.stories.js +0 -99
- package/src/examples/Typography/BodyText.stories.js +0 -58
- package/src/examples/Typography/Caption.stories.js +0 -55
- package/src/examples/Typography/Heading.stories.js +0 -32
- package/src/examples/Typography/Subtitle.stories.js +0 -58
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import ProductLogo from './ProductLogo.vue';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Display/Logos/ProductLogo',
|
|
5
5
|
component: ProductLogo,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
|
|
10
|
-
template: '<ProductLogo alt="primary" id="34" />',
|
|
9
|
+
template: '<farm-imglogo-product alt="primary" id="34" />',
|
|
11
10
|
});
|
|
12
11
|
|
|
13
12
|
Primary.storyName = 'Básico';
|
|
@@ -1,25 +1,34 @@
|
|
|
1
1
|
import MainFilter from './MainFilter.vue';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Form/MainFilter',
|
|
5
5
|
component: MainFilter,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
|
|
10
|
-
template: '<MainFilter />',
|
|
9
|
+
template: '<farm-form-mainfilter />',
|
|
11
10
|
});
|
|
12
11
|
|
|
13
12
|
export const Secondary = () => ({
|
|
14
|
-
|
|
15
|
-
template: '<MainFilter :hasExtraFilters="false" />',
|
|
13
|
+
template: '<farm-form-mainfilter :hasExtraFilters="false" />',
|
|
16
14
|
});
|
|
17
15
|
|
|
18
16
|
export const CustomLabel = () => ({
|
|
19
|
-
|
|
20
|
-
template: '<MainFilter label="Custom" />',
|
|
17
|
+
template: '<farm-form-mainfilter label="Custom" />',
|
|
21
18
|
});
|
|
22
19
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
20
|
+
|
|
21
|
+
export const MainFilters = () => ({
|
|
22
|
+
data() {
|
|
23
|
+
return {
|
|
24
|
+
showFilters: false,
|
|
25
|
+
items: [1, 2, 3, 4, 5],
|
|
26
|
+
};
|
|
27
|
+
},
|
|
28
|
+
template: `<div style="max-width: 480px">
|
|
29
|
+
<farm-form-mainfilter @onClick="showFilters = !showFilters" :showFilters="showFilters" />
|
|
30
|
+
<section v-if="showFilters">
|
|
31
|
+
<v-select :items="items" />
|
|
32
|
+
</section>
|
|
33
|
+
</div>`,
|
|
34
|
+
});
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
@keyup="onKeyUp"
|
|
11
11
|
/>
|
|
12
12
|
</fieldset>
|
|
13
|
-
<farm-
|
|
13
|
+
<farm-btn
|
|
14
14
|
v-if="hasExtraFilters"
|
|
15
15
|
color="secondary"
|
|
16
16
|
class="farm-btn--responsive mt-14 mt-sm-8"
|
|
@@ -18,25 +18,15 @@
|
|
|
18
18
|
>
|
|
19
19
|
<farm-icon class="mr-2">{{ extraFiltersBtnIcon }}</farm-icon>
|
|
20
20
|
{{ extraFiltersBtnLabel }}
|
|
21
|
-
</farm-
|
|
21
|
+
</farm-btn>
|
|
22
22
|
</section>
|
|
23
23
|
</template>
|
|
24
24
|
|
|
25
25
|
<script lang="ts">
|
|
26
26
|
import Vue from 'vue';
|
|
27
|
-
import DefaultButton from '../Buttons/DefaultButton';
|
|
28
|
-
import Icon from '../Icon';
|
|
29
|
-
import Label from '../Label';
|
|
30
|
-
import TextField from '../TextField';
|
|
31
27
|
|
|
32
28
|
export default Vue.extend({
|
|
33
29
|
name: 'farm-form-mainfilter',
|
|
34
|
-
components: {
|
|
35
|
-
'farm-button': DefaultButton,
|
|
36
|
-
'farm-icon': Icon,
|
|
37
|
-
'farm-textfield': TextField,
|
|
38
|
-
'farm-label': Label
|
|
39
|
-
},
|
|
40
30
|
props: {
|
|
41
31
|
/**
|
|
42
32
|
* Show or not button for extra filters
|
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
import ManagersList from './ManagersList';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Display/ManagersList',
|
|
5
5
|
component: ManagersList,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
|
|
10
|
-
template: '<ManagersList managersString="nome1,nome2,nome3" />',
|
|
9
|
+
template: '<farm-managers-list managersString="nome1,nome2,nome3" />',
|
|
11
10
|
});
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Primary.storyName = 'Básico';
|
|
@@ -5,8 +5,10 @@
|
|
|
5
5
|
</li>
|
|
6
6
|
</ul>
|
|
7
7
|
</template>
|
|
8
|
-
<script>
|
|
9
|
-
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import Vue from 'vue';
|
|
10
|
+
export default Vue.extend({
|
|
11
|
+
name: 'farm-managers-list',
|
|
10
12
|
props: {
|
|
11
13
|
managersString: {
|
|
12
14
|
type: String,
|
|
@@ -18,7 +20,7 @@ export default {
|
|
|
18
20
|
return !this.managersString ? [] : this.managersString.split(',');
|
|
19
21
|
},
|
|
20
22
|
},
|
|
21
|
-
};
|
|
23
|
+
});
|
|
22
24
|
</script>
|
|
23
25
|
<style scoped lang="scss">
|
|
24
26
|
ul {
|
|
@@ -1,57 +1,49 @@
|
|
|
1
|
+
import { withDesign } from 'storybook-addon-designs';
|
|
1
2
|
import ModalPromptUser from './ModalPromptUser.vue';
|
|
2
3
|
|
|
3
4
|
export default {
|
|
4
|
-
title: '
|
|
5
|
+
title: 'Interactions/ModalPromptUser',
|
|
5
6
|
component: ModalPromptUser,
|
|
7
|
+
decorators: [withDesign],
|
|
8
|
+
parameters: {
|
|
9
|
+
viewMode: 'docs',
|
|
10
|
+
docs: {
|
|
11
|
+
description: {
|
|
12
|
+
component: `Modal Prompt User to Confirm<br />
|
|
13
|
+
selector: <em>farm-prompt-user</em>`,
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
design: {
|
|
17
|
+
type: 'figma',
|
|
18
|
+
url: 'https://www.figma.com/file/1f84J4m1IBghWhozQvdyyt/%E2%9C%8D---Design-System?node-id=1%3A7',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
6
21
|
};
|
|
7
22
|
|
|
8
23
|
export const Primary = () => ({
|
|
9
|
-
components: { ModalPromptUser },
|
|
10
24
|
data() {
|
|
11
25
|
return {
|
|
12
|
-
showPrompt:
|
|
26
|
+
showPrompt: false,
|
|
13
27
|
};
|
|
14
28
|
},
|
|
15
29
|
template: `<div>
|
|
16
|
-
<
|
|
17
|
-
|
|
30
|
+
<farm-prompt-user match="CONFIRMAR" title="Título" subtitle="Digite CONFIRMAR para habilitar" v-model="showPrompt" />
|
|
31
|
+
click:
|
|
32
|
+
<v-btn color="secondary" @click="showPrompt = true;">
|
|
18
33
|
reabrir
|
|
19
34
|
</v-btn>
|
|
20
35
|
</div>`,
|
|
21
36
|
});
|
|
22
37
|
export const Error = () => ({
|
|
23
|
-
components: { ModalPromptUser },
|
|
24
38
|
data() {
|
|
25
39
|
return {
|
|
26
|
-
showPrompt:
|
|
40
|
+
showPrompt: false,
|
|
27
41
|
};
|
|
28
42
|
},
|
|
29
43
|
template: `<div>
|
|
30
|
-
<
|
|
44
|
+
<farm-prompt-user match="REMOVER" title="Título" subtitle="Digite REMOVER para habilitar" v-model="showPrompt" confirmColor="error" confirmLabel="Remover" />
|
|
31
45
|
<v-btn color="secondary" @click="showPrompt = true;">
|
|
32
46
|
reabrir
|
|
33
47
|
</v-btn>
|
|
34
48
|
</div>`,
|
|
35
49
|
});
|
|
36
|
-
|
|
37
|
-
Primary.story = {
|
|
38
|
-
name: 'Básico',
|
|
39
|
-
parameters: {
|
|
40
|
-
design: {
|
|
41
|
-
type: 'figma',
|
|
42
|
-
url:
|
|
43
|
-
'https://www.figma.com/file/1f84J4m1IBghWhozQvdyyt/%E2%9C%8D---Design-System?node-id=1%3A7',
|
|
44
|
-
},
|
|
45
|
-
},
|
|
46
|
-
};
|
|
47
|
-
|
|
48
|
-
Error.story = {
|
|
49
|
-
name: 'Error',
|
|
50
|
-
parameters: {
|
|
51
|
-
design: {
|
|
52
|
-
type: 'figma',
|
|
53
|
-
url:
|
|
54
|
-
'https://www.figma.com/file/1f84J4m1IBghWhozQvdyyt/%E2%9C%8D---Design-System?node-id=1%3A7',
|
|
55
|
-
},
|
|
56
|
-
},
|
|
57
|
-
};
|
|
@@ -23,16 +23,12 @@
|
|
|
23
23
|
</template>
|
|
24
24
|
<script lang="ts">
|
|
25
25
|
import Vue from 'vue';
|
|
26
|
-
import { DialogHeader, DialogFooter, PromptUserToConfirm } from '../../main';
|
|
27
26
|
import { VDialog } from 'vuetify/lib/components/VDialog';
|
|
28
27
|
import { VMain } from 'vuetify/lib/components/VMain';
|
|
29
28
|
|
|
30
29
|
export default Vue.extend({
|
|
31
30
|
name: 'farm-prompt-user',
|
|
32
31
|
components: {
|
|
33
|
-
DialogHeader,
|
|
34
|
-
DialogFooter,
|
|
35
|
-
PromptUserToConfirm,
|
|
36
32
|
VDialog,
|
|
37
33
|
VMain,
|
|
38
34
|
},
|
|
@@ -1,32 +1,23 @@
|
|
|
1
1
|
import MultipleFilePicker from './MultipleFilePicker.vue';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Form/MultipleFilePicker',
|
|
5
5
|
component: MultipleFilePicker,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
components: { MultipleFilePicker },
|
|
10
9
|
template: '<MultipleFilePicker />',
|
|
11
10
|
});
|
|
12
11
|
|
|
13
12
|
export const MaxFileSize = () => ({
|
|
14
|
-
components: { MultipleFilePicker },
|
|
15
13
|
template: '<MultipleFilePicker :maxFileSize="5" />',
|
|
16
14
|
});
|
|
17
15
|
|
|
18
16
|
export const MaxFilesNumber = () => ({
|
|
19
|
-
components: { MultipleFilePicker },
|
|
20
17
|
template: '<MultipleFilePicker :maxFileSize="5" :maxFilesNumber="1" />',
|
|
21
18
|
});
|
|
22
19
|
|
|
23
20
|
export const Download = () => ({
|
|
24
|
-
components: { MultipleFilePicker },
|
|
25
21
|
template:
|
|
26
22
|
'<MultipleFilePicker :maxFileSize="5" :downloadFiles="[{ id: 1, name: `Arquivo 1`, size: 10000 }, { id: 2, name: `Arquivo 2`, size: 15000 }]" />',
|
|
27
23
|
});
|
|
28
|
-
|
|
29
|
-
Primary.storyName = 'Básico';
|
|
30
|
-
MaxFileSize.storyName = 'Max File Size';
|
|
31
|
-
MaxFilesNumber.storyName = 'Max Files Number';
|
|
32
|
-
Download.storyName = 'Download Files';
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import MultipleSelectShortener from './MultipleSelectShortener';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Display/MultipleSelectShortener',
|
|
5
5
|
component: MultipleSelectShortener,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
components: { MultipleSelectShortener },
|
|
10
9
|
data() {
|
|
11
10
|
return {
|
|
12
11
|
items: {
|
|
@@ -19,19 +18,15 @@ export const Primary = () => ({
|
|
|
19
18
|
});
|
|
20
19
|
|
|
21
20
|
export const Secondary = () => ({
|
|
22
|
-
components: { MultipleSelectShortener },
|
|
23
21
|
data() {
|
|
24
22
|
return {
|
|
25
23
|
items: [
|
|
26
24
|
{
|
|
27
25
|
id: 0,
|
|
28
|
-
label: `Convidar
|
|
26
|
+
label: `Convidar`,
|
|
29
27
|
},
|
|
30
28
|
],
|
|
31
29
|
};
|
|
32
30
|
},
|
|
33
31
|
template: '<MultipleSelectShortener :item="{...items}" :index="1" :itemsLength="3"/>',
|
|
34
32
|
});
|
|
35
|
-
|
|
36
|
-
Primary.storyName = 'Básico';
|
|
37
|
-
Secondary.storyName = 'Multiplos';
|
|
@@ -2,7 +2,7 @@ import { withDesign } from 'storybook-addon-designs';
|
|
|
2
2
|
import ProgressBar from './ProgressBar.vue';
|
|
3
3
|
|
|
4
4
|
export default {
|
|
5
|
-
title: '
|
|
5
|
+
title: 'Feedback/ProgressBar',
|
|
6
6
|
component: ProgressBar,
|
|
7
7
|
decorators: [withDesign],
|
|
8
8
|
parameters: {
|
|
@@ -21,7 +21,6 @@ export default {
|
|
|
21
21
|
};
|
|
22
22
|
|
|
23
23
|
export const Primary = () => ({
|
|
24
|
-
components: { 'farm-progressbar': ProgressBar },
|
|
25
24
|
data() {
|
|
26
25
|
return {
|
|
27
26
|
val: 35,
|
|
@@ -30,14 +29,20 @@ export const Primary = () => ({
|
|
|
30
29
|
template: '<farm-progressbar :value="val" />',
|
|
31
30
|
});
|
|
32
31
|
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
32
|
+
export const CustomColors = () => ({
|
|
33
|
+
data() {
|
|
34
|
+
return {
|
|
35
|
+
val: 35,
|
|
36
|
+
};
|
|
37
37
|
},
|
|
38
|
-
|
|
38
|
+
template: '<farm-progressbar :value="val" backgroundColor="accent" valueColor="secondary" />',
|
|
39
|
+
});
|
|
39
40
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
export const CustomHexaColors = () => ({
|
|
42
|
+
data() {
|
|
43
|
+
return {
|
|
44
|
+
val: 35,
|
|
45
|
+
};
|
|
46
|
+
},
|
|
47
|
+
template: '<farm-progressbar :value="val" backgroundColor="#FFFF00" valueColor="#00FF00" />',
|
|
48
|
+
});
|
|
@@ -1,39 +1,45 @@
|
|
|
1
1
|
import PromptUserToConfirm from './PromptUserToConfirm';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'INteractions/PromptUserToConfirm',
|
|
5
5
|
component: PromptUserToConfirm,
|
|
6
|
+
parameters: {
|
|
7
|
+
viewMode: 'docs',
|
|
8
|
+
docs: {
|
|
9
|
+
description: {
|
|
10
|
+
component: `Prompt User to Confirm<br />
|
|
11
|
+
selector: <em>farm-promptusertoconfirm</em>`,
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
},
|
|
6
15
|
};
|
|
7
16
|
|
|
8
17
|
export const Primary = () => ({
|
|
9
|
-
components: { PromptUserToConfirm },
|
|
10
18
|
data() {
|
|
11
19
|
return {
|
|
12
20
|
model: {},
|
|
13
21
|
};
|
|
14
22
|
},
|
|
15
|
-
template: `<div style="max-width: 320px"><
|
|
23
|
+
template: `<div style="max-width: 320px"><farm-promptusertoconfirm v-model="model"/>
|
|
16
24
|
match: {{ model }}
|
|
17
25
|
</div>`,
|
|
18
26
|
});
|
|
19
27
|
|
|
20
28
|
export const CustomTitle = () => ({
|
|
21
|
-
|
|
22
|
-
template: '<div style="max-width: 320px"><PromptUserToConfirm title="Custom" /></div>',
|
|
29
|
+
template: '<div style="max-width: 320px"><farm-promptusertoconfirm title="Custom" /></div>',
|
|
23
30
|
});
|
|
24
31
|
|
|
25
32
|
export const CustomMatchInput = () => ({
|
|
26
|
-
components: { PromptUserToConfirm },
|
|
27
33
|
data() {
|
|
28
34
|
return {
|
|
29
35
|
model: {},
|
|
30
36
|
};
|
|
31
37
|
},
|
|
32
|
-
template: `<div style="max-width: 320px"
|
|
33
|
-
|
|
38
|
+
template: `<div style="max-width: 320px">
|
|
39
|
+
<farm-promptusertoconfirm
|
|
40
|
+
title="Custom match input: CONFIRMAR"
|
|
41
|
+
match="CONFIRMAR"
|
|
42
|
+
v-model="model" />
|
|
43
|
+
match: {{ model }}
|
|
34
44
|
</div>`,
|
|
35
45
|
});
|
|
36
|
-
|
|
37
|
-
Primary.storyName = 'Básico';
|
|
38
|
-
CustomTitle.storyName = 'Título customizado';
|
|
39
|
-
CustomMatchInput.storyName = 'Match input customizado';
|
|
@@ -15,11 +15,13 @@
|
|
|
15
15
|
</v-row>
|
|
16
16
|
</v-form>
|
|
17
17
|
</template>
|
|
18
|
-
<script>
|
|
18
|
+
<script lang="ts">
|
|
19
|
+
import Vue from 'vue';
|
|
19
20
|
import { VForm } from 'vuetify/lib/components/VForm';
|
|
20
21
|
import { VTextField } from 'vuetify/lib/components/VTextField';
|
|
21
22
|
import { VRow, VCol } from 'vuetify/lib/components/VGrid';
|
|
22
|
-
export default {
|
|
23
|
+
export default Vue.extend({
|
|
24
|
+
name: 'farm-promptusertoconfirm',
|
|
23
25
|
props: {
|
|
24
26
|
/**
|
|
25
27
|
* String to be matched with user prompt
|
|
@@ -71,5 +73,5 @@ export default {
|
|
|
71
73
|
mounted() {
|
|
72
74
|
this.matchInput = null;
|
|
73
75
|
},
|
|
74
|
-
};
|
|
76
|
+
});
|
|
75
77
|
</script>
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import ResetTableRowSelection from './ResetTableRowSelection';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Interactions/ResetTableRowSelection',
|
|
5
5
|
component: ResetTableRowSelection,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
components: { ResetTableRowSelection },
|
|
10
9
|
data() {
|
|
11
10
|
return {
|
|
12
11
|
items: [1, 2, 3],
|
|
@@ -14,5 +13,3 @@ export const Primary = () => ({
|
|
|
14
13
|
},
|
|
15
14
|
template: `<ResetTableRowSelection v-model="items" />`,
|
|
16
15
|
});
|
|
17
|
-
|
|
18
|
-
Primary.storyName = 'Básico';
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import SelectModalOptions from './SelectModalOptions';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'INteractions/SelectModalOptions',
|
|
5
5
|
component: SelectModalOptions,
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export const Primary = () => ({
|
|
9
|
-
components: { SelectModalOptions },
|
|
10
9
|
data() {
|
|
11
10
|
return {
|
|
12
11
|
items: [
|
|
@@ -17,7 +16,7 @@ export const Primary = () => ({
|
|
|
17
16
|
};
|
|
18
17
|
},
|
|
19
18
|
template: `<div>
|
|
20
|
-
<
|
|
19
|
+
<farm-select-modal-options
|
|
21
20
|
:items="items"
|
|
22
21
|
v-model="selectedValue"
|
|
23
22
|
label="label"
|
|
@@ -27,7 +26,6 @@ export const Primary = () => ({
|
|
|
27
26
|
});
|
|
28
27
|
|
|
29
28
|
export const InitialValue = () => ({
|
|
30
|
-
components: { SelectModalOptions },
|
|
31
29
|
data() {
|
|
32
30
|
return {
|
|
33
31
|
items: [
|
|
@@ -38,7 +36,7 @@ export const InitialValue = () => ({
|
|
|
38
36
|
};
|
|
39
37
|
},
|
|
40
38
|
template: `<div>
|
|
41
|
-
<
|
|
39
|
+
<farm-select-modal-options
|
|
42
40
|
:items="items"
|
|
43
41
|
v-model="selectedValue"
|
|
44
42
|
label="label"
|
|
@@ -46,6 +44,3 @@ export const InitialValue = () => ({
|
|
|
46
44
|
<br />selected value: {{ selectedValue }}
|
|
47
45
|
</div>`,
|
|
48
46
|
});
|
|
49
|
-
|
|
50
|
-
Primary.storyName = 'Basic';
|
|
51
|
-
InitialValue.storyName = 'Initial value';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import StepperHeader from './StepperHeader.vue';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: '
|
|
4
|
+
title: 'Navigation/StepperHeader',
|
|
5
5
|
component: StepperHeader,
|
|
6
6
|
parameters: {
|
|
7
7
|
docs: {
|
|
@@ -19,8 +19,14 @@ export default {
|
|
|
19
19
|
},
|
|
20
20
|
};
|
|
21
21
|
|
|
22
|
+
const steps = [
|
|
23
|
+
{ label: 'Solicitação de limite', icon: 'book' },
|
|
24
|
+
{ label: 'Lista impeditiva', icon: 'monitor' },
|
|
25
|
+
{ label: 'Lista pré-elegíveis', icon: 'book' },
|
|
26
|
+
{ label: 'Fila de compliance', icon: 'logout' },
|
|
27
|
+
];
|
|
28
|
+
|
|
22
29
|
export const Primary = () => ({
|
|
23
|
-
components: { 'farm-stepper-header': StepperHeader },
|
|
24
30
|
data() {
|
|
25
31
|
return {
|
|
26
32
|
steps: [
|
|
@@ -35,4 +41,49 @@ export const Primary = () => ({
|
|
|
35
41
|
template: '<farm-stepper-header :steps="steps" :currentStep="currentStep" />',
|
|
36
42
|
});
|
|
37
43
|
|
|
38
|
-
|
|
44
|
+
export const Error = () => ({
|
|
45
|
+
data() {
|
|
46
|
+
return {
|
|
47
|
+
steps,
|
|
48
|
+
currentStep: 3,
|
|
49
|
+
};
|
|
50
|
+
},
|
|
51
|
+
template:
|
|
52
|
+
'<farm-stepper-header :steps="steps" :currentStep="currentStep" :errorCurrentStepStatus="true" />',
|
|
53
|
+
});
|
|
54
|
+
|
|
55
|
+
export const Vertical = () => ({
|
|
56
|
+
data() {
|
|
57
|
+
return {
|
|
58
|
+
steps,
|
|
59
|
+
currentStep: 3,
|
|
60
|
+
};
|
|
61
|
+
},
|
|
62
|
+
template: '<farm-stepper-header :steps="steps" :currentStep="currentStep" vertical />',
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
export const VerticalError = () => ({
|
|
66
|
+
data() {
|
|
67
|
+
return {
|
|
68
|
+
steps,
|
|
69
|
+
currentStep: 3,
|
|
70
|
+
};
|
|
71
|
+
},
|
|
72
|
+
template:
|
|
73
|
+
'<farm-stepper-header :steps="steps" :currentStep="currentStep" vertical :errorCurrentStepStatus="true" />',
|
|
74
|
+
});
|
|
75
|
+
|
|
76
|
+
export const Numbers = () => ({
|
|
77
|
+
data() {
|
|
78
|
+
return {
|
|
79
|
+
steps: [
|
|
80
|
+
{ label: 'Solicitação de limite' },
|
|
81
|
+
{ label: 'Lista impeditiva' },
|
|
82
|
+
{ label: 'Lista pré-elegíveis' },
|
|
83
|
+
{ label: 'Fila de compliance' },
|
|
84
|
+
],
|
|
85
|
+
currentStep: 2,
|
|
86
|
+
};
|
|
87
|
+
},
|
|
88
|
+
template: '<farm-stepper-header :steps="steps" :currentStep="currentStep" />',
|
|
89
|
+
});
|
|
@@ -42,13 +42,9 @@
|
|
|
42
42
|
<script lang="ts">
|
|
43
43
|
import Vue, { PropType } from 'vue';
|
|
44
44
|
import IStep from './IStep';
|
|
45
|
-
import Icon from '../../Icon';
|
|
46
45
|
|
|
47
46
|
export default Vue.extend({
|
|
48
47
|
name: 'farm-stepper-header',
|
|
49
|
-
components: {
|
|
50
|
-
'farm-icon': Icon,
|
|
51
|
-
},
|
|
52
48
|
props: {
|
|
53
49
|
/**
|
|
54
50
|
* Steps
|
|
@@ -2,55 +2,35 @@ import TableContextMenu from './TableContextMenu';
|
|
|
2
2
|
import { withDesign } from 'storybook-addon-designs';
|
|
3
3
|
|
|
4
4
|
export default {
|
|
5
|
-
title: '
|
|
5
|
+
title: 'Navigation/TableContextMenu',
|
|
6
6
|
decorators: [withDesign],
|
|
7
7
|
component: TableContextMenu,
|
|
8
|
+
parameters: {
|
|
9
|
+
design: {
|
|
10
|
+
type: 'figma',
|
|
11
|
+
url: 'https://www.figma.com/file/rkkAsX4IP0tzv1udIDXlqe/%E2%9C%8D---Onboarding---PJ?node-id=3516%3A11516',
|
|
12
|
+
},
|
|
13
|
+
},
|
|
8
14
|
};
|
|
9
15
|
|
|
10
16
|
export const Primary = () => ({
|
|
11
|
-
|
|
12
|
-
template: `<TableContextMenu :items="[{ label: 'Remover' }]" />`,
|
|
17
|
+
template: `<farm-context-menu :items="[{ label: 'Remover' }]" />`,
|
|
13
18
|
});
|
|
14
19
|
|
|
15
20
|
export const Icons = () => ({
|
|
16
|
-
|
|
17
|
-
|
|
21
|
+
template: `<farm-context-menu
|
|
22
|
+
:items="[{ label: 'Remover', icon: { color: 'error', type: 'delete' } }]" />`,
|
|
18
23
|
});
|
|
19
24
|
|
|
20
25
|
export const Multi = () => ({
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
type: 'figma',
|
|
30
|
-
url:
|
|
31
|
-
'https://www.figma.com/file/rkkAsX4IP0tzv1udIDXlqe/%E2%9C%8D---Onboarding---PJ?node-id=3516%3A11516',
|
|
32
|
-
},
|
|
26
|
+
data() {
|
|
27
|
+
return {
|
|
28
|
+
items: [
|
|
29
|
+
{ label: 'Novo', icon: { color: 'grey', type: 'open-in-new' } },
|
|
30
|
+
{ label: 'Editar', icon: { color: 'secondary', type: 'open-in-new' } },
|
|
31
|
+
{ label: 'Remover', icon: { color: 'error', type: 'delete' } },
|
|
32
|
+
],
|
|
33
|
+
};
|
|
33
34
|
},
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
Icons.story = {
|
|
37
|
-
name: 'Ícone',
|
|
38
|
-
parameters: {
|
|
39
|
-
design: {
|
|
40
|
-
type: 'figma',
|
|
41
|
-
url:
|
|
42
|
-
'https://www.figma.com/file/rkkAsX4IP0tzv1udIDXlqe/%E2%9C%8D---Onboarding---PJ?node-id=3516%3A11516',
|
|
43
|
-
},
|
|
44
|
-
},
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
Multi.story = {
|
|
48
|
-
name: 'Múltiplos Itens',
|
|
49
|
-
parameters: {
|
|
50
|
-
design: {
|
|
51
|
-
type: 'figma',
|
|
52
|
-
url:
|
|
53
|
-
'https://www.figma.com/file/rkkAsX4IP0tzv1udIDXlqe/%E2%9C%8D---Onboarding---PJ?node-id=3516%3A11516',
|
|
54
|
-
},
|
|
55
|
-
},
|
|
56
|
-
};
|
|
35
|
+
template: `<farm-context-menu :items="items" />`,
|
|
36
|
+
});
|