cotomy 0.1.69 → 0.1.71

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/esm/form.js CHANGED
@@ -162,7 +162,7 @@ export class CotomyApiForm extends CotomyForm {
162
162
  }
163
163
  export class CotomyEntityApiForm extends CotomyApiForm {
164
164
  get entityKey() {
165
- return this.attribute("data-cotomy-entity-key") ?? undefined;
165
+ return this.attribute("data-cotomy-entity-key") || undefined;
166
166
  }
167
167
  get requiresEntityKey() {
168
168
  return this.attribute("data-cotomy-identify") !== "false";
@@ -220,7 +220,7 @@ export class CotomyEntityApiForm extends CotomyApiForm {
220
220
  this.attribute("data-cotomy-entity-key", addedParts[0]);
221
221
  }
222
222
  else {
223
- const msg = `Location does not contain a single entity key segment.
223
+ const msg = `Location does not contain a single entity key segment.
224
224
  action="${baseAction}", location="${locPath}", added=["${addedParts.join('","')}"]`;
225
225
  throw new Error(msg);
226
226
  }
@@ -328,8 +328,8 @@ export class CotomyEntityFillApiForm extends CotomyEntityApiForm {
328
328
  await this.fillObjectAsync(bindNameGenerator, value, pname);
329
329
  continue;
330
330
  }
331
- this.find(`input[name="${pname}" i]:not([data-cotomy-fill="false"]):not([multiple]),
332
- textarea[name="${pname}" i]:not([data-cotomy-fill="false"]),
331
+ this.find(`input[name="${pname}" i]:not([data-cotomy-fill="false"]):not([multiple]),
332
+ textarea[name="${pname}" i]:not([data-cotomy-fill="false"]),
333
333
  select[name="${pname}" i]:not([data-cotomy-fill="false"]):not([multiple])`).forEach(input => {
334
334
  if (CotomyDebugSettings.isEnabled(CotomyDebugFeature.Fill)) {
335
335
  console.debug(`Filling input[name="${pname}"] with value:`, value);
package/package.json CHANGED
@@ -1,60 +1,61 @@
1
- {
2
- "name": "cotomy",
3
- "version": "0.1.69",
4
- "main": "dist/cjs/index.cjs",
5
- "module": "dist/esm/index.js",
6
- "types": "dist/types/index.d.ts",
7
- "browser": "dist/esm/index.js",
8
- "exports": {
9
- ".": {
10
- "types": "./dist/types/index.d.ts",
11
- "import": "./dist/esm/index.js",
12
- "require": "./dist/cjs/index.cjs",
13
- "default": "./dist/esm/index.js"
14
- },
15
- "./package.json": "./package.json"
16
- },
17
- "files": [
18
- "dist",
19
- "README.md",
20
- "LICENSE"
21
- ],
22
- "unpkg": "dist/browser/cotomy.min.js",
23
- "scripts": {
24
- "build": "npm run clean && npm run build:esm && npm run build:cjs && npm run build:browser",
25
- "build:esm": "tsc --project tsconfig.esm.json",
26
- "build:cjs": "webpack --config webpack.config.cjs --mode=production",
27
- "build:browser": "webpack --config webpack.config.browser.cjs",
28
- "dev": "webpack --config webpack.config.cjs --mode=development",
29
- "clean": "rm -rf dist",
30
- "test": "echo \"(optional) add test runner like vitest or jest\"",
31
- "prepare": "npm run build",
32
- "release": "npm run clean && npm run build && npm version patch && npm publish",
33
- "check": "tsc --noEmit",
34
- "lint": "eslint src --ext .ts",
35
- "format": "prettier --write src"
36
- },
37
- "publishConfig": {
38
- "access": "public"
39
- },
40
- "keywords": [],
41
- "author": "",
42
- "license": "MIT",
43
- "description": "",
44
- "type": "module",
45
- "devDependencies": {
46
- "@types/jsdom": "^27.0.0",
47
- "jsdom": "^27.0.0",
48
- "ts-loader": "^9.5.2",
49
- "typescript": "^5.8.3",
50
- "vitest": "^3.2.4",
51
- "webpack": "^5.99.9",
52
- "webpack-cli": "^6.0.1"
53
- },
54
- "dependencies": {
55
- "cuid": "^3.0.0",
56
- "dayjs": "^1.11.13",
57
- "http-status-codes": "^2.3.0",
58
- "locale-currency": "^0.0.4"
59
- }
60
- }
1
+ {
2
+ "name": "cotomy",
3
+ "version": "0.1.71",
4
+ "main": "dist/cjs/index.cjs",
5
+ "module": "dist/esm/index.js",
6
+ "types": "dist/types/index.d.ts",
7
+ "browser": "dist/esm/index.js",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/types/index.d.ts",
11
+ "import": "./dist/esm/index.js",
12
+ "require": "./dist/cjs/index.cjs",
13
+ "default": "./dist/esm/index.js"
14
+ },
15
+ "./package.json": "./package.json"
16
+ },
17
+ "files": [
18
+ "dist",
19
+ "README.md",
20
+ "LICENSE"
21
+ ],
22
+ "unpkg": "dist/browser/cotomy.min.js",
23
+ "scripts": {
24
+ "build": "npm run clean && npm run build:esm && npm run build:cjs && npm run build:browser",
25
+ "build:esm": "tsc --project tsconfig.esm.json",
26
+ "build:cjs": "webpack --config webpack.config.cjs --mode=production",
27
+ "build:browser": "webpack --config webpack.config.browser.cjs",
28
+ "dev": "webpack --config webpack.config.cjs --mode=development",
29
+ "clean": "rimraf dist",
30
+ "test": "echo \"(optional) add test runner like vitest or jest\"",
31
+ "prepare": "npm run build",
32
+ "release": "npm run clean && npm run build && npm version patch && npm publish",
33
+ "check": "tsc --noEmit",
34
+ "lint": "eslint src --ext .ts",
35
+ "format": "prettier --write src"
36
+ },
37
+ "publishConfig": {
38
+ "access": "public"
39
+ },
40
+ "keywords": [],
41
+ "author": "",
42
+ "license": "MIT",
43
+ "description": "",
44
+ "type": "module",
45
+ "devDependencies": {
46
+ "@types/jsdom": "^27.0.0",
47
+ "jsdom": "^27.0.0",
48
+ "rimraf": "^6.0.1",
49
+ "ts-loader": "^9.5.2",
50
+ "typescript": "^5.8.3",
51
+ "vitest": "^3.2.4",
52
+ "webpack": "^5.99.9",
53
+ "webpack-cli": "^6.0.1"
54
+ },
55
+ "dependencies": {
56
+ "cuid": "^3.0.0",
57
+ "dayjs": "^1.11.13",
58
+ "http-status-codes": "^2.3.0",
59
+ "locale-currency": "^0.0.4"
60
+ }
61
+ }