renusify 1.1.1 → 1.1.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.
@@ -72,7 +72,8 @@ $btn-transition: opacity 0.2s map-get($transition, 'ease-in-out') !default;
72
72
  }
73
73
 
74
74
  &:not(.btn-text):not(.btn-outlined) {
75
- background-color: var(--color-sheet)
75
+ background-color: var(--color-sheet);
76
+ color: var(--color-text-primary)
76
77
  }
77
78
 
78
79
  &.btn-outlined.btn-text {
@@ -37,7 +37,7 @@ export default {
37
37
  },
38
38
  computed: {
39
39
  classes () {
40
- let c = this.$r.prefix+'chip px-3 chip-size-' + this.size
40
+ let c = this.$r.prefix + 'chip chip-size-' + this.size
41
41
  if (this.selectable) {
42
42
  c += ' chip-selectable'
43
43
  }
@@ -47,7 +47,7 @@ $icon-sizes: (
47
47
  display: inline-flex;
48
48
  line-height: 20px;
49
49
  outline: none;
50
- padding: 0;
50
+ padding: 0 12px;
51
51
  position: relative;
52
52
  text-decoration: none;
53
53
  transition-duration: $chip-transition-duration;
@@ -104,7 +104,7 @@ export default {
104
104
  is = image[0] === 'image'
105
105
  if (!is) {
106
106
  const p = this.fileLink.split('.')
107
- is = ['jpg', 'jpeg', 'png', 'gif'].includes(p[p.length - 1])
107
+ is = ['jpg', 'jpeg', 'png', 'gif', 'svg'].includes(p[p.length - 1])
108
108
  }
109
109
  return is
110
110
  },
@@ -2,7 +2,7 @@
2
2
  <div
3
3
  :class="{
4
4
  [`${$r.prefix}input-container`]:true,
5
- [c_color||'color-one-text']:c_color&&!isDisabled,
5
+ [c_color]:c_color&&!isDisabled,
6
6
  'color-error-text':hasError&&genMessages.length>0,
7
7
  'hide-detail':c_hide,
8
8
  'input-focused':active,
@@ -152,7 +152,7 @@ export default {
152
152
  if (this.color === undefined && this.$r.inputs.color) {
153
153
  return this.$r.inputs.color
154
154
  }
155
- return this.color
155
+ return this.color || 'color-one-text'
156
156
  },
157
157
  c_hide() {
158
158
  if (this.hide === undefined && this.$r.inputs.hide) {
@@ -12,6 +12,7 @@
12
12
  :close="multiple&&!textChip"
13
13
  :key="key"
14
14
  :text="textChip || !multiple"
15
+ :class="{'px-0':!multiple}"
15
16
  @update:modelValue="handleChip($event,key)"
16
17
  selectable
17
18
  v-for="(item,key) in chips">
@@ -25,6 +25,7 @@
25
25
  <r-card class="pt-3">
26
26
  <timepicker
27
27
  class="mb-2 mx-3"
28
+ :disableTime="disableTime"
28
29
  :is24-hour="is24Hour"
29
30
  :withSec="withSec"
30
31
  v-model="lazyValue"
@@ -57,6 +58,11 @@ export default {
57
58
  name: "r-time-picker",
58
59
  components: {Timepicker},
59
60
  props: {
61
+ disableTime: {
62
+ type: Function, default: () => {
63
+ return false
64
+ }
65
+ },
60
66
  withSec: Boolean,
61
67
  is24Hour: {type: Boolean, default: true},
62
68
  noOverlay: Boolean,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "renusify",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "Vue3 Framework",
5
5
  "keywords": [
6
6
  "vuejs",
package/tools/helper.js CHANGED
@@ -400,4 +400,24 @@ export function getCookie(cname) {
400
400
  }
401
401
  }
402
402
  return "";
403
+ }
404
+
405
+ export function changeColor(vars) {
406
+ let head = document.head || document.getElementsByTagName('head')[0]
407
+ let children = head.querySelectorAll("[c='color']");
408
+ if (children) {
409
+ let childArray = Array.prototype.slice.call(children);
410
+ childArray.forEach(function (child) {
411
+ child.parentNode.removeChild(child);
412
+ });
413
+ }
414
+ let style = document.createElement('style');
415
+ style.setAttribute("c", "color");
416
+ head.appendChild(style);
417
+ let css = ':root{';
418
+ for (let k in vars) {
419
+ css += k + ':' + vars[k] + ';'
420
+ }
421
+ css += '}'
422
+ style.appendChild(document.createTextNode(css));
403
423
  }