ywana-core8 0.0.496 → 0.0.499
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 +5 -15338
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +5 -15329
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +9 -15333
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/site/site.js +4 -8
- package/src/site/site.test.js +2 -2
- package/src/site/console.js +0 -18
package/package.json
CHANGED
package/src/site/site.js
CHANGED
@@ -5,11 +5,9 @@ import { Header } from '../html/header'
|
|
5
5
|
import { Tooltip } from '../html/tooltip'
|
6
6
|
import { Page } from './page'
|
7
7
|
import { SiteContext } from './siteContext'
|
8
|
-
import './site.css'
|
9
|
-
|
10
8
|
import { ReactNotifications, Store } from 'react-notifications-component'
|
11
9
|
import 'react-notifications-component/dist/theme.css'
|
12
|
-
import
|
10
|
+
import './site.css'
|
13
11
|
|
14
12
|
|
15
13
|
|
@@ -64,13 +62,11 @@ export const SiteProvider = ({ children, siteLang, siteDictionary }) => {
|
|
64
62
|
consoleLines,
|
65
63
|
showConsole,
|
66
64
|
toggleConsole: () => { setShowConsole(!showConsole) },
|
67
|
-
|
65
|
+
writeLog: (line) => {
|
68
66
|
const next = consoleLines.concat(line)
|
69
67
|
setConsoleLines(next)
|
70
68
|
},
|
71
|
-
clearLog: () => {
|
72
|
-
setConsoleLines([])
|
73
|
-
},
|
69
|
+
clearLog: () => { setConsoleLines([])},
|
74
70
|
|
75
71
|
breadcrumb,
|
76
72
|
setBreadcrumb,
|
@@ -331,7 +327,7 @@ const SiteConsole = () => {
|
|
331
327
|
<Icon icon="clear_all" size="small" clickable action={clear} />
|
332
328
|
</nav>
|
333
329
|
<main>
|
334
|
-
{context.consoleLines.map(line => <div>{line}</div>)}
|
330
|
+
{context.consoleLines.map((line,index) => <div key={`log-${index}`}>{line}</div>)}
|
335
331
|
</main>
|
336
332
|
</footer>
|
337
333
|
) : ''
|
package/src/site/site.test.js
CHANGED
@@ -18,7 +18,7 @@ const SiteTest = (prop) => {
|
|
18
18
|
const footer = <div>FOOTER</div>
|
19
19
|
|
20
20
|
return (
|
21
|
-
<Site icon="star" title="Site Test" init={"
|
21
|
+
<Site icon="star" title="Site Test" init={"PAGE2"} footer={footer}>
|
22
22
|
<Page id="PAGE1" section="SECTION1" icon="description" title="Page 1" layout="workspace">
|
23
23
|
<Page1 />
|
24
24
|
</Page>
|
@@ -108,7 +108,7 @@ const Page2 = (props) => {
|
|
108
108
|
}
|
109
109
|
|
110
110
|
function write() {
|
111
|
-
site.
|
111
|
+
site.writeLog("xxx"+new Date())
|
112
112
|
}
|
113
113
|
|
114
114
|
|
package/src/site/console.js
DELETED