@policystudio/policy-studio-ui-vue 1.0.36 → 1.0.39

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.
@@ -18309,6 +18309,10 @@ html {
18309
18309
  border-radius: 1.5rem;
18310
18310
  }
18311
18311
 
18312
+ .psui-el-switch.disabled {
18313
+ pointer-events: none;
18314
+ }
18315
+
18312
18316
  .psui-el-switch.size-big{
18313
18317
  width: 46px;
18314
18318
  height: 24px;
@@ -18723,9 +18727,6 @@ html {
18723
18727
  --text-opacity: 1;
18724
18728
  color: #798490;
18725
18729
  color: rgba(121, 132, 144, var(--text-opacity));
18726
- --bg-opacity: 1;
18727
- background-color: #F3F6F9;
18728
- background-color: rgba(243, 246, 249, var(--bg-opacity));
18729
18730
  }
18730
18731
 
18731
18732
  .psui-el-checkbox.disabled .psui-el-checkmark {
@@ -18774,7 +18775,7 @@ html {
18774
18775
  display: flex;
18775
18776
  cursor: pointer;
18776
18777
  align-items: center;
18777
- height: 18px;
18778
+ height: 100%;
18778
18779
  }
18779
18780
 
18780
18781
  .psui-el-checkbox.size-small .psui-el-checkmark span {
@@ -18823,7 +18824,7 @@ html {
18823
18824
  display: flex;
18824
18825
  cursor: pointer;
18825
18826
  align-items: center;
18826
- height: 24px;
18827
+ height: 100%;
18827
18828
  }
18828
18829
 
18829
18830
  .psui-el-checkbox.size-big .psui-el-checkmark span {
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@policystudio/policy-studio-ui-vue",
3
- "version": "1.0.36",
3
+ "version": "1.0.39",
4
4
  "description": "Policy Studio UI",
5
5
  "main": "src/index.js",
6
6
  "author": "Policy Studio Team",
7
- "url": "https://bitbucket.org/policy-studio/policy-studio-ui-vue",
7
+ "url": "https://github.com/Policy-Studio/policy-studio-ui-vue",
8
8
  "license": "MIT",
9
9
  "keywords": [
10
10
  "vue",
@@ -1,7 +1,7 @@
1
1
  @layer components {
2
2
 
3
3
  .psui-el-checkbox {
4
- @apply psui-relative psui-text-gray-50 psui-bg-gray-10;
4
+ @apply psui-relative psui-text-gray-50;
5
5
 
6
6
  &.disabled {
7
7
  .psui-el-checkmark {
@@ -38,7 +38,7 @@
38
38
  }
39
39
  .psui-el-checkmark {
40
40
  @apply psui-flex psui-cursor-pointer psui-items-center;
41
- height: 18px;
41
+ height: 100%;
42
42
 
43
43
  span {
44
44
  margin-left: 8px;
@@ -77,7 +77,7 @@
77
77
  }
78
78
  .psui-el-checkmark {
79
79
  @apply psui-flex psui-cursor-pointer psui-items-center;
80
- height: 24px;
80
+ height: 100%;
81
81
 
82
82
  span {
83
83
  margin-left: 8px;
@@ -1,6 +1,10 @@
1
1
  @layer components {
2
2
  .psui-el-switch {
3
3
  @apply psui-relative psui-inline-block psui-rounded-3xl;
4
+
5
+ &.disabled {
6
+ pointer-events: none;
7
+ }
4
8
  &.size-big{
5
9
  width: 46px;
6
10
  height: 24px;
@@ -28,7 +28,7 @@ export default {
28
28
  * It sets the value which should be monitored.
29
29
  */
30
30
  inputValue: {
31
- type: String,
31
+ type: [String, Boolean],
32
32
  },
33
33
  value:{
34
34
  type: Array
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <div class='psui-el-switch' :class="getComponentClass" @click="change()">
2
+ <div class='psui-el-switch' :class="[getComponentClass, {'disabled':disabled}]" @click="change()">
3
3
  <input type="checkbox" :checked="value" />
4
4
  <label class='psui-el-switch-button' :class="[getToggleClass]" />
5
5
  </div>
@@ -23,6 +23,13 @@ export default {
23
23
  value:{
24
24
  type: Boolean,
25
25
  },
26
+ /**
27
+ * It sets disabling mode.
28
+ */
29
+ disabled:{
30
+ type: Boolean,
31
+ default: false
32
+ },
26
33
  /**
27
34
  * It sets the size of the switch button. eg: small and big.
28
35
  */
@@ -4,7 +4,9 @@
4
4
  <label v-if="label"> {{ label }} </label>
5
5
 
6
6
  <div
7
- class="psui-el-input-wrapper"
7
+ class="psui-el-input-wrapper"
8
+ @mouseenter="$emit('mouseenter',$event)"
9
+ @mouseleave="$emit('mouseleave',$event)"
8
10
  >
9
11
 
10
12
  <div v-if="$slots.prepend" class="psui-el-input-prepend">
@@ -131,12 +133,10 @@ export default {
131
133
  },
132
134
  methods: {
133
135
  onInputFocus($event) {
134
- console.log('focus')
135
136
  this.isFocus = true
136
137
  this.$emit('focus', $event)
137
138
  },
138
139
  onInputBlur($event) {
139
- console.log('blur')
140
140
  this.isFocus = false
141
141
  this.$emit('blur', $event)
142
142
  }
@@ -22,8 +22,8 @@ const Template = (args, { argTypes }) => ({
22
22
  </div>
23
23
  <div style='display: flex; gap: 10px; flex-direction: column;'>
24
24
  <span>Disable</span>
25
- <PsSwitch v-bind="$props" v-model="dt" label='Switch1' size='big'/>
26
- <PsSwitch v-bind="$props" v-model="dt" label='Switch2' size='small'/>
25
+ <PsSwitch v-bind="$props" v-model="dt" label='Switch1' disabled size='big'/>
26
+ <PsSwitch v-bind="$props" v-model="dt" label='Switch2' disabled size='small'/>
27
27
  </div>
28
28
  <div style='display: flex; gap: 10px; flex-direction: column;'>
29
29
  <span>Enable</span>