@burh/nuxt-core 1.0.456 → 1.0.458

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.
@@ -1,114 +1,114 @@
1
- <template>
2
- <component
3
- :is="tag"
4
- :class="[{ show: isOpen }, `drop${direction}`]"
5
- @click="toggleDropDown"
6
- v-click-outside="closeDropDown"
7
- >
8
- <slot name="title-container" :is-open="isOpen">
9
- <component
10
- :is="titleTag"
11
- class="btn-rotate"
12
- :class="[{'dropdown-toggle': hasToggle}, titleClasses]"
13
- :aria-expanded="isOpen"
14
- data-toggle="dropdown"
15
- >
16
- <slot name="title" :is-open="isOpen">
17
- <i :class="icon"></i> {{ title }}
18
- </slot>
19
- </component>
20
- </slot>
21
- <ul
22
- class="dropdown-menu"
23
- :class="[
24
- { show: isOpen },
25
- { 'dropdown-menu-right': menuOnRight },
26
- menuClasses
27
- ]"
28
- >
29
- <slot></slot>
30
- </ul>
31
- </component>
32
- </template>
33
- <script>
34
- export default {
35
- name: 'base-dropdown',
36
- props: {
37
- tag: {
38
- type: String,
39
- default: 'div',
40
- description: 'Dropdown html tag (e.g div, ul etc)'
41
- },
42
- titleTag: {
43
- type: String,
44
- default: 'button',
45
- description: 'Dropdown title (toggle) html tag'
46
- },
47
- title: {
48
- type: String,
49
- description: 'Dropdown title'
50
- },
51
- direction: {
52
- type: String,
53
- default: 'down', // up | down
54
- description: 'Dropdown menu direction (up|down)'
55
- },
56
- icon: {
57
- type: String,
58
- description: 'Dropdown icon'
59
- },
60
- titleClasses: {
61
- type: [String, Object, Array],
62
- description: 'Title css classes'
63
- },
64
- menuClasses: {
65
- type: [String, Object],
66
- description: 'Menu css classes'
67
- },
68
- menuOnRight: {
69
- type: Boolean,
70
- description: 'Whether menu should appear on the right'
71
- },
72
- hasToggle: {
73
- type: Boolean,
74
- description: 'Whether dropdown has arrow icon shown',
75
- default: true
76
- },
77
- isDropdownOpen: {
78
- type: Boolean,
79
- default: false
80
- }
81
- },
82
- data() {
83
- return {
84
- isOpen: false
85
- };
86
- },
87
- watch: {
88
- isOpen() {
89
- if (this.isOpen === false) {
90
- this.$emit('close');
91
- }
92
- },
93
- isDropdownOpen() {
94
- this.isOpen = this.isDropdownOpen;
95
- }
96
- },
97
- methods: {
98
- toggleDropDown() {
99
- this.isOpen = !this.isOpen;
100
- this.$emit('change', this.isOpen);
101
- },
102
- closeDropDown() {
103
- this.isOpen = false;
104
- this.$emit('change', false);
105
- }
106
- }
107
- };
108
- </script>
109
- <style lang="scss" scoped>
110
- .dropdown {
111
- cursor: pointer;
112
- user-select: none;
113
- }
114
- </style>
1
+ <template>
2
+ <component
3
+ :is="tag"
4
+ :class="[{ show: isOpen }, `drop${direction}`]"
5
+ @click="toggleDropDown"
6
+ v-click-outside="closeDropDown"
7
+ >
8
+ <slot name="title-container" :is-open="isOpen">
9
+ <component
10
+ :is="titleTag"
11
+ class="btn-rotate"
12
+ :class="[{'dropdown-toggle': hasToggle}, titleClasses]"
13
+ :aria-expanded="isOpen"
14
+ data-toggle="dropdown"
15
+ >
16
+ <slot name="title" :is-open="isOpen">
17
+ <i :class="icon"></i> {{ title }}
18
+ </slot>
19
+ </component>
20
+ </slot>
21
+ <ul
22
+ class="dropdown-menu"
23
+ :class="[
24
+ { show: isOpen },
25
+ { 'dropdown-menu-right': menuOnRight },
26
+ menuClasses
27
+ ]"
28
+ >
29
+ <slot></slot>
30
+ </ul>
31
+ </component>
32
+ </template>
33
+ <script>
34
+ export default {
35
+ name: 'base-dropdown',
36
+ props: {
37
+ tag: {
38
+ type: String,
39
+ default: 'div',
40
+ description: 'Dropdown html tag (e.g div, ul etc)'
41
+ },
42
+ titleTag: {
43
+ type: String,
44
+ default: 'button',
45
+ description: 'Dropdown title (toggle) html tag'
46
+ },
47
+ title: {
48
+ type: String,
49
+ description: 'Dropdown title'
50
+ },
51
+ direction: {
52
+ type: String,
53
+ default: 'down', // up | down
54
+ description: 'Dropdown menu direction (up|down)'
55
+ },
56
+ icon: {
57
+ type: String,
58
+ description: 'Dropdown icon'
59
+ },
60
+ titleClasses: {
61
+ type: [String, Object, Array],
62
+ description: 'Title css classes'
63
+ },
64
+ menuClasses: {
65
+ type: [String, Object],
66
+ description: 'Menu css classes'
67
+ },
68
+ menuOnRight: {
69
+ type: Boolean,
70
+ description: 'Whether menu should appear on the right'
71
+ },
72
+ hasToggle: {
73
+ type: Boolean,
74
+ description: 'Whether dropdown has arrow icon shown',
75
+ default: true
76
+ },
77
+ isDropdownOpen: {
78
+ type: Boolean,
79
+ default: false
80
+ }
81
+ },
82
+ data() {
83
+ return {
84
+ isOpen: false
85
+ };
86
+ },
87
+ watch: {
88
+ isOpen() {
89
+ if (this.isOpen === false) {
90
+ this.$emit('close');
91
+ }
92
+ },
93
+ isDropdownOpen() {
94
+ this.isOpen = this.isDropdownOpen;
95
+ }
96
+ },
97
+ methods: {
98
+ toggleDropDown() {
99
+ this.isOpen = !this.isOpen;
100
+ this.$emit('change', this.isOpen);
101
+ },
102
+ closeDropDown() {
103
+ this.isOpen = false;
104
+ this.$emit('change', false);
105
+ }
106
+ }
107
+ };
108
+ </script>
109
+ <style lang="scss" scoped>
110
+ .dropdown {
111
+ cursor: pointer;
112
+ user-select: none;
113
+ }
114
+ </style>
@@ -1,26 +1,26 @@
1
- <template>
2
- <div class="row" v-loading="true" id="loading"></div>
3
- </template>
4
- <script>
5
- import Vue from 'vue';
6
- import { Loading } from 'element-ui';
7
-
8
- Vue.use(Loading.directive);
9
- export default {};
10
- </script>
11
- <style>
12
- #loading {
13
- min-height: 200px;
14
- display: flex;
15
- align-items: center;
16
- }
17
-
18
- .el-loading-spinner .path {
19
- stroke: #66615b !important;
20
- }
21
-
22
- .el-loading-mask {
23
- z-index: 100!important;
24
- background: transparent !important;
25
- }
26
- </style>
1
+ <template>
2
+ <div class="row" v-loading="true" id="loading"></div>
3
+ </template>
4
+ <script>
5
+ import Vue from 'vue';
6
+ import { Loading } from 'element-ui';
7
+
8
+ Vue.use(Loading.directive);
9
+ export default {};
10
+ </script>
11
+ <style>
12
+ #loading {
13
+ min-height: 200px;
14
+ display: flex;
15
+ align-items: center;
16
+ }
17
+
18
+ .el-loading-spinner .path {
19
+ stroke: #66615b !important;
20
+ }
21
+
22
+ .el-loading-mask {
23
+ z-index: 100!important;
24
+ background: transparent !important;
25
+ }
26
+ </style>
@@ -1,74 +1,74 @@
1
- <template>
2
- <div class="feature__card">
3
- <div class="feature__card__image" :style="`--icon-bg-color: #${iconBgColor}`">
4
- <img :src="icon" :alt="title">
5
- </div>
6
- <div class="feature__card__title">
7
- <p>{{ title }}</p>
8
- </div>
9
- <div class="feature__card__description">
10
- <span>{{ description }}</span>
11
- </div>
12
- </div>
13
- </template>
14
-
15
- <script>
16
- export default {
17
- name: 'FeatureBusinessCard',
18
- props: {
19
- icon: String,
20
- iconBgColor: {
21
- type: String,
22
- default: '5983FE'
23
- },
24
- title: String,
25
- description: String,
26
- }
27
- };
28
- </script>
29
-
30
- <style lang="scss" scoped>
31
- .feature__card {
32
- background: #fff;
33
- padding: 20px;
34
- display: flex;
35
- flex-direction: column;
36
- align-items: flex-start;
37
- box-shadow: 5px 5px 50px 2px #E9EEF2;
38
- border-radius: 10px;
39
- width: 100%;
40
- min-width: 300px;
41
- margin: 0 auto;
42
- transition: transform 0.25s, box-shadow 0.5s;
43
- &__image {
44
- display: flex;
45
- align-items: center;
46
- justify-content: center;
47
- width: 45px;
48
- height: 45px;
49
- border-radius: 10px;
50
- background: var(--icon-bg-color);
51
- img {
52
- display: block;
53
- width: 25px;
54
- }
55
- }
56
- &__title {
57
- padding: 10px 0;
58
- p {
59
- font-size: 1.5625rem;
60
- font-weight: 600;
61
- margin-bottom: 0;
62
- }
63
- }
64
- &__description {
65
- text-align: left;
66
- font-weight: 400;
67
- font-size: 0.875rem;
68
- }
69
- &:hover {
70
- transform: translateY(-10px);
71
- box-shadow: 7px 15px 20px rgba(0, 0, 0, 0.05);
72
- }
73
- }
74
- </style>
1
+ <template>
2
+ <div class="feature__card">
3
+ <div class="feature__card__image" :style="`--icon-bg-color: #${iconBgColor}`">
4
+ <img :src="icon" :alt="title">
5
+ </div>
6
+ <div class="feature__card__title">
7
+ <p>{{ title }}</p>
8
+ </div>
9
+ <div class="feature__card__description">
10
+ <span>{{ description }}</span>
11
+ </div>
12
+ </div>
13
+ </template>
14
+
15
+ <script>
16
+ export default {
17
+ name: 'FeatureBusinessCard',
18
+ props: {
19
+ icon: String,
20
+ iconBgColor: {
21
+ type: String,
22
+ default: '5983FE'
23
+ },
24
+ title: String,
25
+ description: String,
26
+ }
27
+ };
28
+ </script>
29
+
30
+ <style lang="scss" scoped>
31
+ .feature__card {
32
+ background: #fff;
33
+ padding: 20px;
34
+ display: flex;
35
+ flex-direction: column;
36
+ align-items: flex-start;
37
+ box-shadow: 5px 5px 50px 2px #E9EEF2;
38
+ border-radius: 10px;
39
+ width: 100%;
40
+ min-width: 300px;
41
+ margin: 0 auto;
42
+ transition: transform 0.25s, box-shadow 0.5s;
43
+ &__image {
44
+ display: flex;
45
+ align-items: center;
46
+ justify-content: center;
47
+ width: 45px;
48
+ height: 45px;
49
+ border-radius: 10px;
50
+ background: var(--icon-bg-color);
51
+ img {
52
+ display: block;
53
+ width: 25px;
54
+ }
55
+ }
56
+ &__title {
57
+ padding: 10px 0;
58
+ p {
59
+ font-size: 1.5625rem;
60
+ font-weight: 600;
61
+ margin-bottom: 0;
62
+ }
63
+ }
64
+ &__description {
65
+ text-align: left;
66
+ font-weight: 400;
67
+ font-size: 0.875rem;
68
+ }
69
+ &:hover {
70
+ transform: translateY(-10px);
71
+ box-shadow: 7px 15px 20px rgba(0, 0, 0, 0.05);
72
+ }
73
+ }
74
+ </style>
@@ -1,81 +1,81 @@
1
- <template>
2
- <card class="card">
3
- <h4 class="aria-text">Funcionalidades</h4>
4
- <ul class="list-unstyled list line-card">
5
- <functionality-item
6
- class="cursor-pointer card-item"
7
- :icone="firstItemIcon"
8
- :text="firstItemText"
9
- @functionality-click="$emit('click-first-item')"
10
- />
11
- <functionality-item
12
- class="cursor-pointer border-left card-item"
13
- :icone="secondItemIcon"
14
- :text="secondItemText"
15
- @functionality-click="$emit('click-second-item')"
16
- />
17
- </ul>
18
- <hr />
19
- <h6 class="list-title font-weight-bold">{{ title }}</h6>
20
- <ul class="list-unstyled list line-card">
21
- <slot></slot>
22
- </ul>
23
- <p class="footer-text">{{ context }}</p>
24
- </card>
25
- </template>
26
- <script>
27
- import FunctionalityItem from './FunctionalityItem';
28
- export default {
29
- name: 'performance-card',
30
- components: {
31
- FunctionalityItem
32
- },
33
- props: {
34
- title: String,
35
- context: String,
36
- firstItemText: String,
37
- secondItemText: String,
38
- firstItemIcon: String,
39
- secondItemIcon: String,
40
- subscribers: Number,
41
- jobs: Number,
42
- visualization: Number,
43
- skeleton: {
44
- type: Boolean,
45
- default: false
46
- }
47
- }
48
- };
49
- </script>
50
- <style lang="scss" scoped>
51
- hr {
52
- border-color: #e9ecef;
53
- }
54
-
55
- .list {
56
- margin: 1.8rem 0;
57
- display: flex;
58
- justify-content: space-evenly;
59
- }
60
-
61
- .line-card {
62
- ul {
63
- &:not(:first-child) {
64
- border: 2px solid #e9ecef;
65
- }
66
- }
67
- }
68
-
69
- .card-item {
70
- width: 50%;
71
- }
72
-
73
- .footer-text {
74
- margin-left: 1rem;
75
- opacity: 0.4;
76
- font-size: smaller;
77
- }
78
- .padding-border {
79
- padding-left: 7.5rem;
80
- }
81
- </style>
1
+ <template>
2
+ <card class="card">
3
+ <h4 class="aria-text">Funcionalidades</h4>
4
+ <ul class="list-unstyled list line-card">
5
+ <functionality-item
6
+ class="cursor-pointer card-item"
7
+ :icone="firstItemIcon"
8
+ :text="firstItemText"
9
+ @functionality-click="$emit('click-first-item')"
10
+ />
11
+ <functionality-item
12
+ class="cursor-pointer border-left card-item"
13
+ :icone="secondItemIcon"
14
+ :text="secondItemText"
15
+ @functionality-click="$emit('click-second-item')"
16
+ />
17
+ </ul>
18
+ <hr />
19
+ <h6 class="list-title font-weight-bold">{{ title }}</h6>
20
+ <ul class="list-unstyled list line-card">
21
+ <slot></slot>
22
+ </ul>
23
+ <p class="footer-text">{{ context }}</p>
24
+ </card>
25
+ </template>
26
+ <script>
27
+ import FunctionalityItem from './FunctionalityItem';
28
+ export default {
29
+ name: 'performance-card',
30
+ components: {
31
+ FunctionalityItem
32
+ },
33
+ props: {
34
+ title: String,
35
+ context: String,
36
+ firstItemText: String,
37
+ secondItemText: String,
38
+ firstItemIcon: String,
39
+ secondItemIcon: String,
40
+ subscribers: Number,
41
+ jobs: Number,
42
+ visualization: Number,
43
+ skeleton: {
44
+ type: Boolean,
45
+ default: false
46
+ }
47
+ }
48
+ };
49
+ </script>
50
+ <style lang="scss" scoped>
51
+ hr {
52
+ border-color: #e9ecef;
53
+ }
54
+
55
+ .list {
56
+ margin: 1.8rem 0;
57
+ display: flex;
58
+ justify-content: space-evenly;
59
+ }
60
+
61
+ .line-card {
62
+ ul {
63
+ &:not(:first-child) {
64
+ border: 2px solid #e9ecef;
65
+ }
66
+ }
67
+ }
68
+
69
+ .card-item {
70
+ width: 50%;
71
+ }
72
+
73
+ .footer-text {
74
+ margin-left: 1rem;
75
+ opacity: 0.4;
76
+ font-size: smaller;
77
+ }
78
+ .padding-border {
79
+ padding-left: 7.5rem;
80
+ }
81
+ </style>
@@ -57,7 +57,7 @@
57
57
 
58
58
  <div
59
59
  class="deficiency title-block mt-3 ml-4"
60
- v-if="userData.user_deficiency"
60
+ v-if="userData.deficiency"
61
61
  >
62
62
  <div class="d-flex align-items-center">
63
63
  <i class="fas fa-wheelchair"></i>
@@ -65,35 +65,38 @@
65
65
  </div>
66
66
  <div class="line"></div>
67
67
  <p>
68
- {{ userData.user_deficiency.deficiency_id | allDeficiencies }} -
69
- {{ userData.user_deficiency.cid }}
68
+ {{ userData && userData.deficiency && userData.deficiency && userData.deficiency.deficiency_id | allDeficiencies }}
69
+
70
+ <template> - </template>
71
+
72
+ {{ userData && userData.deficiency && userData.deficiency && userData.deficiency.cid | formatCid }}
70
73
  </p>
71
74
 
72
- <p v-show="userData.user_deficiency.appliance">
73
- Acessório: {{ userData.user_deficiency.appliance }}
75
+ <p v-if="userData && userData.deficiency && userData.deficiency.appliance || false">
76
+ Acessório: {{ userData.deficiency.appliance }}
74
77
  </p>
75
78
 
76
- <p v-show="userData.user_deficiency.apparatus">
77
- Necessidade: {{ userData.user_deficiency.apparatus }}
79
+ <p v-if="userData && userData.deficiency && userData.deficiency.apparatus || false">
80
+ Necessidade: {{ userData.deficiency.apparatus }}
78
81
  </p>
79
82
 
80
- <p v-show="userData.user_deficiency.course">
81
- Curso: {{ userData.user_deficiency.course }}
83
+ <p v-if="userData && userData.deficiency && userData.deficiency.course || false">
84
+ Curso: {{ userData.deficiency.course }}
82
85
  </p>
83
86
 
84
- <p v-show="userData.user_deficiency.note">
85
- Anotações: {{ userData.user_deficiency.note }}
87
+ <p v-if="userData && userData.deficiency && userData.deficiency.note || false">
88
+ Anotações: {{ userData.deficiency.note }}
86
89
  </p>
87
90
 
88
- <p v-show="userData.user_deficiency.transport === 1">
91
+ <p v-if="userData && userData.deficiency && userData.deficiency.transport === 1 || false">
89
92
  Utiliza transporte coletivo
90
93
  </p>
91
94
 
92
- <p v-show="userData.user_deficiency.vehicle === 1">
95
+ <p v-if="userData && userData.deficiency && userData.deficiency.vehicle === 1 || false">
93
96
  Possuí veículo adaptado
94
97
  </p>
95
98
 
96
- <p v-show="userData.user_deficiency.escort === 1">
99
+ <p v-if="userData && userData.deficiency && userData.deficiency.escort === 1 || false">
97
100
  Precisa de acompanhante
98
101
  </p>
99
102
  </div>
@@ -344,7 +347,7 @@ export default {
344
347
  }
345
348
  },
346
349
  filters: {
347
- allDeficiencies(id) {
350
+ allDeficiencies(idList) {
348
351
  const typeDeficiency = {
349
352
  1: 'Deficiência Física',
350
353
  2: 'Deficiência Visual',
@@ -354,7 +357,10 @@ export default {
354
357
  6: 'Deficiência Múltipla'
355
358
  };
356
359
 
357
- return typeDeficiency[id] || '-';
360
+ return idList && idList.length && idList.map(id => typeDeficiency[id] || null).filter(id => id).join(' | ') || '';
361
+ },
362
+ formatCid(cidList) {
363
+ return cidList && cidList.length && cidList.filter(cid => cid).join(' | ') || '';
358
364
  },
359
365
  convertMoney(money) {
360
366
  let moneyAux = parseFloat(money);