@rindo/core 2.17.1 → 2.17.2-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.
package/mock-doc/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Rindo Mock Doc v2.17.1 | MIT Licensed | https://rindojs.web.app
2
+ Rindo Mock Doc v2.17.2-0 | MIT Licensed | https://rindojs.web.app
3
3
  */
4
4
  const CONTENT_REF_ID = 'r';
5
5
  const ORG_LOCATION_ID = 'o';
@@ -686,6 +686,25 @@ class MockMouseEvent extends MockEvent {
686
686
  }
687
687
  }
688
688
  }
689
+ class MockUIEvent extends MockEvent {
690
+ constructor(type, uiEventInitDic) {
691
+ super(type);
692
+ this.detail = null;
693
+ this.view = null;
694
+ if (uiEventInitDic != null) {
695
+ Object.assign(this, uiEventInitDic);
696
+ }
697
+ }
698
+ }
699
+ class MockFocusEvent extends MockUIEvent {
700
+ constructor(type, focusEventInitDic) {
701
+ super(type);
702
+ this.relatedTarget = null;
703
+ if (focusEventInitDic != null) {
704
+ Object.assign(this, focusEventInitDic);
705
+ }
706
+ }
707
+ }
689
708
  class MockEventListener {
690
709
  constructor(type, handler) {
691
710
  this.type = type;
@@ -1600,7 +1619,7 @@ class MockElement extends MockNode {
1600
1619
  return shadowRoot;
1601
1620
  }
1602
1621
  blur() {
1603
- /**/
1622
+ dispatchEvent(this, new MockFocusEvent('blur', { relatedTarget: null, bubbles: true, cancelable: true, composed: true }));
1604
1623
  }
1605
1624
  get shadowRoot() {
1606
1625
  return this.__shadowRoot || null;
@@ -1670,7 +1689,9 @@ class MockElement extends MockNode {
1670
1689
  get firstElementChild() {
1671
1690
  return this.children[0] || null;
1672
1691
  }
1673
- focus(_options) { }
1692
+ focus(_options) {
1693
+ dispatchEvent(this, new MockFocusEvent('focus', { relatedTarget: null, bubbles: true, cancelable: true, composed: true }));
1694
+ }
1674
1695
  getAttribute(attrName) {
1675
1696
  if (attrName === 'style') {
1676
1697
  if (this.__style != null && this.__style.length > 0) {
@@ -3429,6 +3450,7 @@ const WINDOW_PROPS = [
3429
3450
  'HTMLElement',
3430
3451
  'Node',
3431
3452
  'NodeList',
3453
+ 'FocusEvent',
3432
3454
  'KeyboardEvent',
3433
3455
  'MouseEvent',
3434
3456
  ];
@@ -3436,6 +3458,7 @@ const GLOBAL_CONSTRUCTORS = [
3436
3458
  ['CustomEvent', MockCustomEvent],
3437
3459
  ['Event', MockEvent],
3438
3460
  ['Headers', MockHeaders],
3461
+ ['FocusEvent', MockFocusEvent],
3439
3462
  ['KeyboardEvent', MockKeyboardEvent],
3440
3463
  ['MouseEvent', MockMouseEvent],
3441
3464
  ['Request', MockRequest],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rindo/core/mock-doc",
3
- "version": "2.17.1",
3
+ "version": "2.17.2-0",
4
4
  "description": "Mock window, document and DOM outside of a browser environment.",
5
5
  "main": "./index.cjs",
6
6
  "module": "./index.js",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rindo/core",
3
- "version": "2.17.1",
3
+ "version": "2.17.2-0",
4
4
  "license": "MIT",
5
5
  "main": "./internal/rindo-core/index.cjs",
6
6
  "module": "./internal/rindo-core/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rindo/core/screenshot",
3
- "version": "2.17.1",
3
+ "version": "2.17.2-0",
4
4
  "description": "Rindo Screenshot.",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
package/sys/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Rindo Node System v2.17.1 | MIT Licensed | https://rindojs.web.app
2
+ Rindo Node System v2.17.2-0 | MIT Licensed | https://rindojs.web.app
3
3
  */
4
4
  function _interopDefaultLegacy(e) {
5
5
  return e && "object" == typeof e && "default" in e ? e : {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rindo/core/sys/node",
3
- "version": "2.17.1",
3
+ "version": "2.17.2-0",
4
4
  "description": "Rindo Node System.",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Rindo Node System Worker v2.17.1 | MIT Licensed | https://rindojs.web.app
2
+ Rindo Node System Worker v2.17.2-0 | MIT Licensed | https://rindojs.web.app
3
3
  */
4
4
  function _interopNamespace(e) {
5
5
  if (e && e.__esModule) return e;
package/testing/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Rindo Testing v2.17.1 | MIT Licensed | https://rindojs.web.app
2
+ Rindo Testing v2.17.2-0 | MIT Licensed | https://rindojs.web.app
3
3
  */
4
4
  function _lazyRequire(e) {
5
5
  return new Proxy({}, {
@@ -460,7 +460,7 @@ function mockConfig(e) {
460
460
  enableCache: !1,
461
461
  buildAppCore: !1,
462
462
  buildDist: !0,
463
- flags: {},
463
+ flags: createConfigFlags(),
464
464
  bundles: null,
465
465
  outputTargets: null,
466
466
  buildEs5: !1,
@@ -3044,7 +3044,7 @@ const createSystem = e => {
3044
3044
  u("/");
3045
3045
  const D = {
3046
3046
  name: "in-memory",
3047
- version: "2.17.1",
3047
+ version: "2.17.2-0",
3048
3048
  events: i,
3049
3049
  access: async e => c(e),
3050
3050
  accessSync: c,
@@ -3416,6 +3416,14 @@ class TestingLogger {
3416
3416
  printDiagnostics(e) {}
3417
3417
  }
3418
3418
 
3419
+ const createConfigFlags = (e = {}) => ({
3420
+ task: null,
3421
+ args: [],
3422
+ knownArgs: [],
3423
+ unknownArgs: [],
3424
+ ...e
3425
+ });
3426
+
3419
3427
  class EventSpy {
3420
3428
  constructor(e) {
3421
3429
  this.eventName = e, this.events = [], this.cursor = 0, this.queuedHandler = [];
@@ -3984,7 +3992,7 @@ exports.createJestPuppeteerEnvironment = function createJestPuppeteerEnvironment
3984
3992
  }), exports.mockValidatedConfig = function mockValidatedConfig(e) {
3985
3993
  return {
3986
3994
  ...mockConfig(e),
3987
- flags: {},
3995
+ flags: createConfigFlags(),
3988
3996
  logger: mockLogger()
3989
3997
  };
3990
3998
  }, exports.mockWindow = function mockWindow(e = null) {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rindo/core/testing",
3
- "version": "2.17.1",
3
+ "version": "2.17.2-0",
4
4
  "description": "Rindo testing suite.",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",