ywana-core8 0.0.990 → 0.0.992

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.
@@ -1,5 +1,5 @@
1
1
  import 'material-design-icons-iconfont/dist/material-design-icons.css';
2
- import React, { useContext, useState, useEffect, useCallback, Fragment, useRef as useRef$1, useMemo, Children } from 'react';
2
+ import React, { useContext, useState, useEffect, useCallback, Fragment, useRef, useMemo, Children } from 'react';
3
3
  import ResumableJS from 'resumablejs';
4
4
  import RSwitch from 'react-switch';
5
5
  import moment$1 from 'moment';
@@ -1673,7 +1673,7 @@ var PasswordField = function PasswordField(props) {
1673
1673
  var UploadArea = function UploadArea(props) {
1674
1674
  var _props$label = props.label,
1675
1675
  label = _props$label === void 0 ? 'Add file or drop file here...' : _props$label;
1676
- var areaElement = useRef$1();
1676
+ var areaElement = useRef();
1677
1677
  var _useState = useState(false),
1678
1678
  drag = _useState[0],
1679
1679
  setDrag = _useState[1];
@@ -1707,7 +1707,7 @@ var UploadIcon = function UploadIcon(_ref) {
1707
1707
  var _ref$icon = _ref.icon,
1708
1708
  icon = _ref$icon === void 0 ? "folder_open" : _ref$icon,
1709
1709
  resumable = _ref.resumable;
1710
- var iconElement = useRef$1();
1710
+ var iconElement = useRef();
1711
1711
  useEffect(function () {
1712
1712
  if (resumable && iconElement.current) {
1713
1713
  resumable.assignBrowse(iconElement.current);
@@ -3198,13 +3198,13 @@ var ImageViewer = function ImageViewer(_ref) {
3198
3198
  var _useState3 = useState(false),
3199
3199
  draggind = _useState3[0],
3200
3200
  setDragging = _useState3[1];
3201
- var touch = useRef$1({
3201
+ var touch = useRef({
3202
3202
  x: 0,
3203
3203
  y: 0
3204
3204
  });
3205
- var canvasRef = useRef$1(null);
3206
- var containerRef = useRef$1(null);
3207
- var observer = useRef$1(null);
3205
+ var canvasRef = useRef(null);
3206
+ var containerRef = useRef(null);
3207
+ var observer = useRef(null);
3208
3208
  var background = useMemo(function () {
3209
3209
  return new Image();
3210
3210
  }, [image]);
@@ -3932,7 +3932,7 @@ var Planner = function Planner(_ref) {
3932
3932
  var _useState3 = useState(config.to),
3933
3933
  to = _useState3[0],
3934
3934
  setTo = _useState3[1];
3935
- var thisMondayElement = useRef$1(null);
3935
+ var thisMondayElement = useRef(null);
3936
3936
  var gotoMonday = useCallback(function (node) {
3937
3937
  var element = node;
3938
3938
  if (element) element.scrollIntoView({
@@ -5284,7 +5284,7 @@ var Wizard = function Wizard(props) {
5284
5284
  valid = _useState3[0],
5285
5285
  setValid = _useState3[1];
5286
5286
  var steps = React.Children.toArray(children);
5287
- var stepRef = useRef$1();
5287
+ var stepRef = useRef();
5288
5288
  function validate(form, isValid) {
5289
5289
  setValid(isValid);
5290
5290
  }
@@ -5529,12 +5529,13 @@ var TaskContextProvider = function TaskContextProvider(props) {
5529
5529
  url = _props$url === void 0 ? "/tasks" : _props$url,
5530
5530
  _props$frequency = props.frequency,
5531
5531
  frequency = _props$frequency === void 0 ? 1000 : _props$frequency,
5532
- children = props.children;
5532
+ children = props.children,
5533
+ ctx = props.ctx;
5533
5534
  var API = CollectionAPI$1(url, host, "");
5534
5535
  var _useState = useState({}),
5535
5536
  listeners = _useState[0],
5536
5537
  setListeners = _useState[1];
5537
- var appContext = useContext(appContext);
5538
+ var appContext = useContext(ctx);
5538
5539
  var appContextRef = useRef(appContext);
5539
5540
  useEffect(function () {
5540
5541
  appContextRef.current = appContext;
@@ -8022,7 +8023,7 @@ var CollectionEditor$1 = function CollectionEditor(props) {
8022
8023
  patch = _props$patch2 === void 0 ? false : _props$patch2,
8023
8024
  actions = props.actions,
8024
8025
  validator = props.validator;
8025
- var timer = useRef$1(null);
8026
+ var timer = useRef(null);
8026
8027
  var _useState5 = useState(selected),
8027
8028
  form = _useState5[0],
8028
8029
  setForm = _useState5[1];
@@ -8419,7 +8420,7 @@ var TablePage = function TablePage(props) {
8419
8420
  var context = TableContext$2(url, field, host, urlQuery, params);
8420
8421
  var all = pageContext.all,
8421
8422
  selected = pageContext.selected;
8422
- var timer = useRef$1(null);
8423
+ var timer = useRef(null);
8423
8424
  var _useState = useState(selected),
8424
8425
  form = _useState[0],
8425
8426
  setForm = _useState[1];
@@ -9343,7 +9344,7 @@ var TablePage2 = function TablePage2(props) {
9343
9344
  setPageContext = _useContext[1];
9344
9345
  var context = TableContext$1(url, field, host, urlQuery, params);
9345
9346
  var selected = pageContext.selected;
9346
- var timer = useRef$1(null);
9347
+ var timer = useRef(null);
9347
9348
  var _useState = useState(selected),
9348
9349
  form = _useState[0],
9349
9350
  setForm = _useState[1];
@@ -10317,7 +10318,7 @@ var TabbedTablePage = function TabbedTablePage(props) {
10317
10318
  var context = TableContext(url, field, host, urlQuery);
10318
10319
  var selected = pageContext.selected,
10319
10320
  tab = pageContext.tab;
10320
- var timer = useRef$1(null);
10321
+ var timer = useRef(null);
10321
10322
  var _useState = useState(selected),
10322
10323
  form = _useState[0],
10323
10324
  setForm = _useState[1];