@farm-investimentos/front-mfe-components 11.0.0 → 11.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@farm-investimentos/front-mfe-components",
3
- "version": "11.0.0",
3
+ "version": "11.0.1",
4
4
  "author": "farm investimentos",
5
5
  "private": false,
6
6
  "main": "./dist/front-mfe-components.common.js",
@@ -144,7 +144,7 @@
144
144
  color: var(--farm-#{$color}-base);
145
145
  }
146
146
 
147
- i.mdi {
147
+ ::v-deep .farm-btn__content i.mdi {
148
148
  color: var(--farm-#{$color}-base);
149
149
  }
150
150
  }
@@ -64,3 +64,12 @@ export const NoIcon = () => ({
64
64
  </farm-card-context>
65
65
  `,
66
66
  });
67
+
68
+ export const TooltipText = () => ({
69
+ template: `
70
+ <farm-card-context tooltipText="Lorem Ipsum is simply dummy text of the printing and typesetting industry" icon="mdi-currency-usd" title="Titulo do Card">
71
+ <p>Conteúdo do Card</p>
72
+ </farm-card-context>
73
+ `,
74
+ });
75
+
@@ -9,9 +9,22 @@
9
9
  <div class="card-context-header" v-if="isSuccess && title">
10
10
  <farm-icon-box v-if="icon" :icon="icon" />
11
11
  <div class="card-context-content">
12
- <p :class="{ 'card-context-title': true, 'card-context-content--bold': bold }">
13
- {{ title }}
14
- </p>
12
+ <div class="d-flex align-center">
13
+ <p :class="{
14
+ 'mr-2': true,
15
+ 'mb-1': true,
16
+ 'card-context-title': true,
17
+ 'card-context-content--bold': bold }"
18
+ >
19
+ {{ title }}
20
+ </p>
21
+ <farm-tooltip v-if="tooltipText !== null">
22
+ {{ tooltipText }}
23
+ <template v-slot:activator="{}">
24
+ <farm-icon size="sm" color="gray">help-circle</farm-icon>
25
+ </template>
26
+ </farm-tooltip>
27
+ </div>
15
28
  </div>
16
29
  </div>
17
30
  <div class="card-context-body" v-if="isSuccess">
@@ -93,6 +106,13 @@ export default Vue.extend({
93
106
  type: Boolean,
94
107
  default: false,
95
108
  },
109
+ /**
110
+ * Show Tooltip and help text
111
+ */
112
+ tooltipText: {
113
+ type: String,
114
+ default: null,
115
+ }
96
116
  },
97
117
  computed: {
98
118
  isSuccess() {
@@ -12,25 +12,4 @@
12
12
  position: relative;
13
13
  }
14
14
 
15
- @each $k in $justifications {
16
- &#{'--justify-' + $k} {
17
- >div {
18
- justify-content: $k;
19
- }
20
- }
21
- }
22
-
23
- @each $k in $directions {
24
- &#{'--direction-' + $k} {
25
- >div {
26
- flex-direction: $k;
27
- }
28
- }
29
- }
30
-
31
- @each $k in map-keys($gutters) {
32
- &#{'[gutter=' + $k + ']'} {
33
- padding: map-get($gutters, $k);
34
- }
35
- }
36
15
  }
@@ -1,5 +1,4 @@
1
1
  import Box from './Box.vue';
2
- import { directions, justifications } from '../../../configurations/flexVariables';
3
2
  import gutters from '../../../configurations/gutters';
4
3
 
5
4
  export default {
@@ -30,42 +29,6 @@ export const Tag = () => ({
30
29
  </div>`,
31
30
  });
32
31
 
33
- export const Justify = () => ({
34
- data() {
35
- return {
36
- justifications,
37
- };
38
- },
39
- template: `<div>
40
- <farm-box :justify="k" v-for="k in justifications" :key="'justify-_' + k" style="border:1px solid var(--farm-stroke-base); margin-bottom: 16px;">
41
- <div>
42
- justify {{ k }}
43
- </div>
44
- <div>
45
- another div
46
- </div>
47
- </farm-box>
48
- </div>`,
49
- });
50
-
51
- export const Directions = () => ({
52
- data() {
53
- return {
54
- directions,
55
- };
56
- },
57
- template: `<div>
58
- <farm-box :direction="k" v-for="k in directions" :key="'direction-_' + k" style="border:1px solid var(--farm-stroke-base); margin-bottom: 16px;">
59
- <div>
60
- direction {{ k }}
61
- </div>
62
- <div>
63
- another div
64
- </div>
65
- </farm-box>
66
- </div>`,
67
- });
68
-
69
32
  export const Gutters = () => ({
70
33
  data() {
71
34
  return { gutters };
@@ -3,8 +3,6 @@
3
3
  :is="tag"
4
4
  :class="{
5
5
  'farm-box': true,
6
- [`farm-box--justify-${justify}`]: justify,
7
- [`farm-box--direction-${direction}`]: direction,
8
6
  }"
9
7
  :gutter="gutter"
10
8
  >
@@ -23,20 +21,6 @@ export default Vue.extend({
23
21
  * Html tag
24
22
  */
25
23
  tag: { type: String, default: 'div' },
26
- /**
27
- * Applies the flex-direction css property
28
- */
29
- direction: {
30
- type: String as PropType<'row' | 'row-reverse' | 'column' | 'column-reverse'>,
31
- default: 'row',
32
- },
33
- /**
34
- * Applies the justify-content css property
35
- */
36
- justify: {
37
- type: String as PropType<'start' | 'center' | 'end' | 'space-between' | 'space-around'>,
38
- default: '',
39
- },
40
24
  /**
41
25
  * Add gutter
42
26
  */