@atlaskit/editor-plugin-date 4.1.7 → 4.1.9

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/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @atlaskit/editor-plugin-date
2
2
 
3
+ ## 4.1.9
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 4.1.8
10
+
11
+ ### Patch Changes
12
+
13
+ - [#137676](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/137676)
14
+ [`4a54b4a64712e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4a54b4a64712e) -
15
+ ED-27338: clean up vanilla date implementation
16
+ - Updated dependencies
17
+
3
18
  ## 4.1.7
4
19
 
5
20
  ### Patch Changes
@@ -9,6 +9,7 @@ var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/cl
9
9
  var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
10
10
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
11
11
  var _bindEventListener = require("bind-event-listener");
12
+ var _monitoring = require("@atlaskit/editor-common/monitoring");
12
13
  var _model = require("@atlaskit/editor-prosemirror/model");
13
14
  var _actions = require("../pm-plugins/actions");
14
15
  var _dateNodeSpec = require("./dateNodeSpec");
@@ -35,6 +36,7 @@ var DateNodeView = exports.DateNodeView = /*#__PURE__*/function () {
35
36
  }
36
37
  });
37
38
  } catch (error) {
39
+ DateNodeView.logError(error instanceof Error ? error : new Error('Unknown error on DateNodeView constructor'));
38
40
  this.renderFallback();
39
41
  }
40
42
  }
@@ -50,5 +52,12 @@ var DateNodeView = exports.DateNodeView = /*#__PURE__*/function () {
50
52
  value: function destroy() {
51
53
  this.clickUnBind && this.clickUnBind();
52
54
  }
55
+ }], [{
56
+ key: "logError",
57
+ value: function logError(error) {
58
+ void (0, _monitoring.logException)(error, {
59
+ location: 'editor-plugin-date/DateNodeView'
60
+ });
61
+ }
53
62
  }]);
54
63
  }();
@@ -1,9 +1,15 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import { bind } from 'bind-event-listener';
3
+ import { logException } from '@atlaskit/editor-common/monitoring';
3
4
  import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
4
5
  import { setDatePickerAt } from '../pm-plugins/actions';
5
6
  import { dateToDOM } from './dateNodeSpec';
6
7
  export class DateNodeView {
8
+ static logError(error) {
9
+ void logException(error, {
10
+ location: 'editor-plugin-date/DateNodeView'
11
+ });
12
+ }
7
13
  constructor(node, view, getPos, intl) {
8
14
  _defineProperty(this, "dom", document.createElement('span'));
9
15
  this.node = node;
@@ -28,6 +34,7 @@ export class DateNodeView {
28
34
  }
29
35
  });
30
36
  } catch (error) {
37
+ DateNodeView.logError(error instanceof Error ? error : new Error('Unknown error on DateNodeView constructor'));
31
38
  this.renderFallback();
32
39
  }
33
40
  }
@@ -2,6 +2,7 @@ import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
2
2
  import _createClass from "@babel/runtime/helpers/createClass";
3
3
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
4
4
  import { bind } from 'bind-event-listener';
5
+ import { logException } from '@atlaskit/editor-common/monitoring';
5
6
  import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
6
7
  import { setDatePickerAt } from '../pm-plugins/actions';
7
8
  import { dateToDOM } from './dateNodeSpec';
@@ -28,6 +29,7 @@ export var DateNodeView = /*#__PURE__*/function () {
28
29
  }
29
30
  });
30
31
  } catch (error) {
32
+ DateNodeView.logError(error instanceof Error ? error : new Error('Unknown error on DateNodeView constructor'));
31
33
  this.renderFallback();
32
34
  }
33
35
  }
@@ -43,5 +45,12 @@ export var DateNodeView = /*#__PURE__*/function () {
43
45
  value: function destroy() {
44
46
  this.clickUnBind && this.clickUnBind();
45
47
  }
48
+ }], [{
49
+ key: "logError",
50
+ value: function logError(error) {
51
+ void logException(error, {
52
+ location: 'editor-plugin-date/DateNodeView'
53
+ });
54
+ }
46
55
  }]);
47
56
  }();
@@ -7,6 +7,7 @@ export declare class DateNodeView implements NodeView {
7
7
  private readonly node;
8
8
  private clickUnBind;
9
9
  readonly dom: HTMLElement;
10
+ private static logError;
10
11
  constructor(node: PMNode, view: EditorView, getPos: getPosHandlerNode, intl: IntlShape);
11
12
  private renderFallback;
12
13
  destroy(): void;
@@ -7,6 +7,7 @@ export declare class DateNodeView implements NodeView {
7
7
  private readonly node;
8
8
  private clickUnBind;
9
9
  readonly dom: HTMLElement;
10
+ private static logError;
10
11
  constructor(node: PMNode, view: EditorView, getPos: getPosHandlerNode, intl: IntlShape);
11
12
  private renderFallback;
12
13
  destroy(): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-date",
3
- "version": "4.1.7",
3
+ "version": "4.1.9",
4
4
  "description": "Date plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -37,7 +37,7 @@
37
37
  "@atlaskit/calendar": "^17.1.0",
38
38
  "@atlaskit/css": "^0.10.0",
39
39
  "@atlaskit/date": "^2.0.0",
40
- "@atlaskit/editor-common": "^102.18.0",
40
+ "@atlaskit/editor-common": "^103.0.0",
41
41
  "@atlaskit/editor-plugin-analytics": "^2.2.0",
42
42
  "@atlaskit/editor-plugin-annotation": "^2.2.0",
43
43
  "@atlaskit/editor-plugin-editor-disabled": "^2.0.0",
@@ -51,7 +51,7 @@
51
51
  "@atlaskit/textfield": "^8.0.0",
52
52
  "@atlaskit/theme": "^18.0.0",
53
53
  "@atlaskit/tmp-editor-statsig": "^4.6.0",
54
- "@atlaskit/tokens": "^4.6.0",
54
+ "@atlaskit/tokens": "^4.7.0",
55
55
  "@babel/runtime": "^7.0.0",
56
56
  "bind-event-listener": "^3.0.0",
57
57
  "date-fns": "^2.17.0",