@brightspace-ui/core 3.296.0 → 3.297.0

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.
@@ -268,21 +268,6 @@ const SELECTORS = {
268
268
  export class TableWrapper extends FreshnessMixin(PageableMixin(SelectionMixin(LitElement))) {
269
269
 
270
270
  static properties = {
271
- /**
272
- * Todo: remove once consumers are updated to freshness. Use freshness instead.
273
- * @ignore
274
- */
275
- dataState: { reflect: true, type: String },
276
- /**
277
- * Todo: remove once consumers are updated to freshness-stale-text. Use freshness-stale-text instead.
278
- * @ignore
279
- */
280
- dirtyText: { reflect: true, attribute: 'dirty-text', type: String },
281
- /**
282
- * Todo: remove once consumers are updated to freshness-stale-button-text. Use freshness-stale-button-text instead.
283
- * @ignore
284
- */
285
- dirtyButtonText: { reflect: true, attribute: 'dirty-button-text', type: String },
286
271
  /**
287
272
  * Hides the column borders on "default" table type
288
273
  * @type {boolean}
@@ -448,19 +433,6 @@ export class TableWrapper extends FreshnessMixin(PageableMixin(SelectionMixin(Li
448
433
  }
449
434
  }
450
435
 
451
- willUpdate(changedProperties) {
452
- super.willUpdate(changedProperties);
453
-
454
- // Todo: remove these once consumers are updated to freshness properties
455
- if (this.dataState) {
456
- if (this.dataState === 'clean') this.freshness = freshness.fresh;
457
- else if (this.dataState === 'dirty') this.freshness = freshness.stale;
458
- else if (this.dataState === 'loading') this.freshness = freshness.loading;
459
- }
460
- if (this.dirtyText) this.freshnessStaleText = this.dirtyText;
461
- if (this.dirtyButtonText) this.freshnessStaleButtonText = this.dirtyButtonText;
462
- }
463
-
464
436
  #hasIntersected = false;
465
437
 
466
438
  #noScrollWidthTimeout = null;
@@ -620,9 +592,6 @@ export class TableWrapper extends FreshnessMixin(PageableMixin(SelectionMixin(Li
620
592
  _handleStaleButton() {
621
593
  /** Dispatched when the action button on the stale overlay is clicked */
622
594
  this.dispatchEvent(new CustomEvent('d2l-table-stale-button-click'));
623
-
624
- /** @ignore Todo: remove once consumers are updated to d2l-table-stale-button-click */
625
- this.dispatchEvent(new CustomEvent('d2l-table-dirty-button-clicked'));
626
595
  }
627
596
 
628
597
  async _handleTableChange(mutationRecords) {
@@ -1,3 +1,4 @@
1
+ const degreesPerRadian = 57.3;
1
2
  const maxTime = 2000;
2
3
  const minDistance = 30;
3
4
 
@@ -50,16 +51,16 @@ function handleTouchStart(e) {
50
51
  // angle of arc from y (deg)
51
52
  if (distanceY > 0 && distanceX > 0) {
52
53
  // swipe down and right
53
- theta = (Math.PI - theta) * 57.3;
54
+ theta = (Math.PI - theta) * degreesPerRadian;
54
55
  } else if (distanceY > 0 && distanceX < 0) {
55
56
  // swipe down and left
56
- theta = (Math.PI + theta) * 57.3;
57
+ theta = (Math.PI + theta) * degreesPerRadian;
57
58
  } else if (distanceY < 0 && distanceX > 0) {
58
59
  // swipe up and right
59
- theta = theta * 57.3;
60
+ theta = theta * degreesPerRadian;
60
61
  } else if (distanceY < 0 && distanceX < 0) {
61
62
  // swipe up and left
62
- theta = ((2 * Math.PI) - theta) * 57.3;
63
+ theta = ((2 * Math.PI) - theta) * degreesPerRadian;
63
64
  }
64
65
 
65
66
  let horizontal = 'none';
@@ -87,7 +88,7 @@ function handleTouchStart(e) {
87
88
  y: distanceY
88
89
  },
89
90
  direction: {
90
- angle: theta,
91
+ angle: theta, // deg, clock-wise from y-axis (12:00 position is 0deg)
91
92
  horizontal: horizontal,
92
93
  vertical: vertical
93
94
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspace-ui/core",
3
- "version": "3.296.0",
3
+ "version": "3.297.0",
4
4
  "description": "A collection of accessible, free, open-source web components for building Brightspace applications",
5
5
  "type": "module",
6
6
  "repository": "https://github.com/BrightspaceUI/core.git",