diginet-core-ui 1.3.95 → 1.3.96

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/icons/effect.js CHANGED
@@ -105,19 +105,19 @@ Icon.propTypes = {
105
105
  viewBox: PropTypes.bool,
106
106
  /** Width of the component. */
107
107
  width: PropTypes.oneOfType([PropTypes.string, PropTypes.number])
108
- /**
109
- * ref methods (ref.current.instance.*method*)
110
- *
111
- * * option(): Gets all UI component properties
112
- * * Returns value - object
113
- * * option(optionName): Gets the value of a single property
114
- * * @param {optionName} - string
115
- * * Returns value - any
116
- * * option(optionName, optionValue): Updates the value of a single property
117
- * * @param {optionName} - string
118
- * * @param {optionValue} - any
119
- * * option(options): Updates the values of several properties
120
- * * @param {options} - object
108
+ /**
109
+ * ref methods (ref.current.instance.*method*)
110
+ *
111
+ * * option(): Gets all UI component properties
112
+ * * Returns value - object
113
+ * * option(optionName): Gets the value of a single property
114
+ * * @param {optionName} - string
115
+ * * Returns value - any
116
+ * * option(optionName, optionValue): Updates the value of a single property
117
+ * * @param {optionName} - string
118
+ * * @param {optionValue} - any
119
+ * * option(options): Updates the values of several properties
120
+ * * @param {options} - object
121
121
  */
122
122
  };
123
123
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "diginet-core-ui",
3
- "version": "1.3.95",
3
+ "version": "1.3.96",
4
4
  "description": "The DigiNet core ui",
5
5
  "homepage": "https://diginet.com.vn",
6
6
  "main": "index.js",
package/readme.md CHANGED
@@ -38,8 +38,15 @@ npm test
38
38
  ```
39
39
 
40
40
  ## Changelog
41
+ ## 1.3.96
42
+ - \[Changed\]: Popover – Add prop onOpen
43
+ - \[Changed\]: ButtonMore – Add tooltip for icon
44
+ - \[Changed\]: Modal – Add onScroll to ModalBody
45
+ - \[Changed\]: Colors – Add dynamic colors
46
+ - \[Changed\]: Utils – Export hexToRGBA
47
+ - \[Fixed\]: DateRangePicker – Fix UI min-width
48
+
41
49
  ## 1.3.95
42
- - \[Added\]: Icon – Add ModuleView, Update ListView, FolderPerson, FolderAdd
43
50
  - \[Added\]: IconMenu – Add WEO76APP0001, WEO76APP0002, WEO76LIS0001, WEO76LIS0002, WEO76LIS0003, WEO76REQ0001, WEO76REQ0002, MHRP09N0033, MHRP29N0029, MHRM89N0002
44
51
  - \[Changed\]: Modal – Change logic of children and title in ModalHeader
45
52
  - \[Fixed\]: TreeView – Fix cannot select by checkbox
@@ -47,6 +54,7 @@ npm test
47
54
  - \[Fixed\]: TECH – Fix warning 'ref is not a prop'
48
55
 
49
56
  ## 1.3.94
57
+ - \[Added\]: Icon – Add ModuleView, Update ListView, FolderPerson, FolderAdd
50
58
  - \[Added\]: Icon – Add color default
51
59
  - \[Changed\]: Breadcrumb – Update design
52
60
  - \[Changed\]: Button – Add text sentence for Button
package/styles/colors.js CHANGED
@@ -323,6 +323,13 @@ color.line = {
323
323
  category: color.dark2,
324
324
  tab: color.dark2
325
325
  };
326
+ color.dynamic = {
327
+ aqua: color.aqua5,
328
+ pistachio: color.pistachio5,
329
+ pumpkin: color.pumpkin5,
330
+ magenta: color.magenta5,
331
+ violet: color.violet5
332
+ };
326
333
  color.primary = color.system.active;
327
334
  color.secondary = color.system.rest;
328
335
  color.success = color.semantic.success;
@@ -0,0 +1,23 @@
1
+ import { isColor, isColorName } from "../../styles/color-helper";
2
+ import { getColor } from "../../styles/utils";
3
+
4
+ /**
5
+ * Convert from #ffffff to rgba()
6
+ * @param hex color - #ffffff
7
+ * @param {number} alpha - 0.5
8
+ * @returns {string} color - rgba()
9
+ */
10
+ export const hexToRGBA = (hex, alpha) => {
11
+ hex = getColor(hex);
12
+ if (isColorName(hex)) hex = isColorName(hex);
13
+ if (!isColor(hex)) return;
14
+ var r = parseInt(hex.slice(1, 3), 16),
15
+ g = parseInt(hex.slice(3, 5), 16),
16
+ b = parseInt(hex.slice(5, 7), 16);
17
+ if (alpha) {
18
+ return 'rgba(' + r + ', ' + g + ', ' + b + ', ' + alpha + ')';
19
+ } else {
20
+ return 'rgb(' + r + ', ' + g + ', ' + b + ')';
21
+ }
22
+ };
23
+ export default hexToRGBA;
package/utils/index.js CHANGED
@@ -5,6 +5,7 @@ export { default as classNames } from "./classNames";
5
5
  export { default as date } from "./date";
6
6
  export { default as getFileType } from "./getFileType";
7
7
  export { default as handleBreakpoints } from "./handleBreakpoints";
8
+ export { default as hexToRGBA } from "./hexToRGBA";
8
9
  export { default as isMobile } from "./isMobile";
9
10
  export { default as mapParent } from "./map-parent";
10
11
  export { default as onValidate } from "./validate";