ywana-core8 0.0.584 → 0.0.585
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/dist/index.cjs +9 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +9 -0
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +9 -0
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/html/accordion.js +7 -1
- package/src/html/table.js +2 -2
- package/src/http/token.test.js +2 -3
- package/src/widgets/planner/Planner.js +1 -1
package/package.json
CHANGED
package/src/html/accordion.js
CHANGED
@@ -2,6 +2,9 @@ import React, {useState, useEffect} from 'react'
|
|
2
2
|
import { Icon } from './icon'
|
3
3
|
import './accordion.css'
|
4
4
|
|
5
|
+
/**
|
6
|
+
* Accordion
|
7
|
+
*/
|
5
8
|
export const Accordion = (props) => {
|
6
9
|
|
7
10
|
const { className, sections = [], onCheck } = props
|
@@ -41,6 +44,9 @@ export const Accordion = (props) => {
|
|
41
44
|
)
|
42
45
|
}
|
43
46
|
|
47
|
+
/**
|
48
|
+
* AccordionSection
|
49
|
+
*/
|
44
50
|
const AccordionSection = (props) => {
|
45
51
|
|
46
52
|
const { checked, icon, title, subtitle, open = false, onToggle, onCheck, toolbar, info, children } = props
|
@@ -48,7 +54,7 @@ const AccordionSection = (props) => {
|
|
48
54
|
const checkedIcon = checked === undefined || checked === null ? null : checked === false ? "check_box_outline_blank" : "check_box"
|
49
55
|
|
50
56
|
return (
|
51
|
-
<section className={`accordion-section`}>
|
57
|
+
<section key={title} className={`accordion-section`}>
|
52
58
|
<header>
|
53
59
|
{ checkedIcon ? <Icon className="accordion-section-checker" icon={checkedIcon} clickable action={onCheck}/> : '' }
|
54
60
|
{ icon ? <Icon className="accordion-section-icon" icon={icon} /> : '' }
|
package/src/html/table.js
CHANGED
@@ -111,7 +111,7 @@ export const DataTable = (props) => {
|
|
111
111
|
</thead>
|
112
112
|
<tbody>
|
113
113
|
{rows.length > 0 ?
|
114
|
-
multiSort(rows, sortDir).map((row,index) => (
|
114
|
+
multiSort(rows, sortDir).map((row, index) => (
|
115
115
|
<DataTableRow key={row.id} index={index} row={row} columns={columns} onSelect={select} onDrop={moveRow} editable={editable} expanded={expanded} />
|
116
116
|
)) : (
|
117
117
|
<tr>
|
@@ -138,7 +138,7 @@ const DataTableRow = (props) => {
|
|
138
138
|
const { className } = row
|
139
139
|
const [isInfoOpen, toggleInfo] = useState(expanded)
|
140
140
|
const infoIcon = isInfoOpen ? 'expand_more' : 'expand_less'
|
141
|
-
const style = isInfoOpen ? "expanded" : ""
|
141
|
+
const style = isInfoOpen ? "expanded" : ""
|
142
142
|
return (
|
143
143
|
<Fragment>
|
144
144
|
<tr className={`${style} ${className}`} onClick={ev => onSelect(row, ev)}>
|
package/src/http/token.test.js
CHANGED
@@ -7,9 +7,8 @@ import { useEffect } from 'react/cjs/react.production.min';
|
|
7
7
|
const Token = () => {
|
8
8
|
|
9
9
|
const [encrypted, setEncrypted] = useState("")
|
10
|
-
const [decrypted, setDecrypted] = useState("")
|
10
|
+
const [decrypted, setDecrypted] = useState("1")
|
11
11
|
|
12
|
-
|
13
12
|
function decryptData(encrypted, secret) {
|
14
13
|
const bytes = CryptoJS.AES.decrypt(encrypted, secret);
|
15
14
|
const originalText = bytes.toString(CryptoJS.enc.Utf8);
|
@@ -21,7 +20,7 @@ const Token = () => {
|
|
21
20
|
}
|
22
21
|
|
23
22
|
function change(id, value) {
|
24
|
-
const secret = '
|
23
|
+
const secret = 'BCDF956E21C79A36';
|
25
24
|
const e = encryptData(value, secret)
|
26
25
|
setEncrypted(e)
|
27
26
|
const d = decryptData(e, secret)
|
@@ -137,7 +137,7 @@ export const Planner = ({ title, events = [], lanes = [], navigation = true, onS
|
|
137
137
|
const isThisMonday = (date.moment.isSame(weekStart))
|
138
138
|
|
139
139
|
return (
|
140
|
-
<div className="column-header" ref={isThisMonday ? thisMondayElement : null}>
|
140
|
+
<div key={`column-${date.moment.dayOfYear}`} className="column-header" ref={isThisMonday ? thisMondayElement : null}>
|
141
141
|
<div className={`date-header ${weekend} ${thisWeek}`}>
|
142
142
|
<Text use="headline6">{date.moment.format("DD")}</Text>
|
143
143
|
|