@projectcaluma/ember-form 11.0.0-beta.10 → 11.0.0-beta.11

Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,16 @@
1
+ # [@projectcaluma/ember-form-v11.0.0-beta.11](https://github.com/projectcaluma/ember-caluma/compare/@projectcaluma/ember-form-v11.0.0-beta.10...@projectcaluma/ember-form-v11.0.0-beta.11) (2022-02-16)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **form:** always use monday as first day of the week in datepicker ([7008a90](https://github.com/projectcaluma/ember-caluma/commit/7008a90d737d2dca714f4799f846f4c4086ecd4d))
7
+ * **form:** use action button type "button" ([3e9795f](https://github.com/projectcaluma/ember-caluma/commit/3e9795f28b73dcf376ec9ecabcd4c1b6a8085beb))
8
+
9
+
10
+ ### Features
11
+
12
+ * **form:** add notfound named block in cf-content if no document found ([f1861c1](https://github.com/projectcaluma/ember-caluma/commit/f1861c1f3b2da9843771aa1b12956190c98799a6))
13
+
1
14
  # [@projectcaluma/ember-form-v11.0.0-beta.10](https://github.com/projectcaluma/ember-caluma/compare/@projectcaluma/ember-form-v11.0.0-beta.9...@projectcaluma/ember-form-v11.0.0-beta.10) (2022-02-09)
2
15
 
3
16
 
@@ -36,4 +36,6 @@
36
36
  <content.form />
37
37
  {{/if}}
38
38
  {{/let}}
39
+ {{else}}
40
+ {{yield to="notfound"}}
39
41
  {{/if}}
@@ -12,7 +12,6 @@
12
12
  @beforeMutate={{fn this.beforeMutate validate}}
13
13
  @onSuccess={{this.onSuccess}}
14
14
  @onError={{this.onError}}
15
- @type={{this.type}}
16
15
  class={{if @disabled "uk-hidden"}}
17
16
  />
18
17
  </DocumentValidity>
@@ -38,12 +38,6 @@ export default class CfFieldInputActionButtonComponent extends Component {
38
38
  return this.args.field.question.raw.color.toLowerCase();
39
39
  }
40
40
 
41
- get type() {
42
- return this.args.field.question.raw.action === "COMPLETE"
43
- ? "submit"
44
- : "button";
45
- }
46
-
47
41
  get validateOnEnter() {
48
42
  return (
49
43
  this.args.field.question.raw.action === "COMPLETE" &&
@@ -19,6 +19,7 @@
19
19
  name={{@field.pk}}
20
20
  id={{@field.pk}}
21
21
  {{pikaday
22
+ firstDay=1
22
23
  toString=this.formatDate
23
24
  i18n=this.pikadayTranslations
24
25
  value=@field.answer.value
@@ -4,6 +4,9 @@ import Component from "@glimmer/component";
4
4
  import { DateTime, Info } from "luxon";
5
5
  import { cached } from "tracked-toolbox";
6
6
 
7
+ // put the last element to the front of the array
8
+ const shift = (array) => [...array.slice(-1), ...array.slice(0, -1)];
9
+
7
10
  export default class CfFieldInputDateComponent extends Component {
8
11
  @service intl;
9
12
 
@@ -30,8 +33,8 @@ export default class CfFieldInputDateComponent extends Component {
30
33
  previousMonth: this.intl.t("caluma.form.pikaday.month-previous"),
31
34
  nextMonth: this.intl.t("caluma.form.pikaday.month-next"),
32
35
  months: Info.months("long", { locale }),
33
- weekdays: Info.weekdays("long", { locale }),
34
- weekdaysShort: Info.weekdays("short", { locale }),
36
+ weekdays: shift(Info.weekdays("long", { locale })),
37
+ weekdaysShort: shift(Info.weekdays("short", { locale })),
35
38
  };
36
39
  }
37
40
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@projectcaluma/ember-form",
3
- "version": "11.0.0-beta.10",
3
+ "version": "11.0.0-beta.11",
4
4
  "description": "Ember addon for rendering Caluma forms.",
5
5
  "keywords": [
6
6
  "ember-addon"
@@ -43,9 +43,9 @@
43
43
  "devDependencies": {
44
44
  "@ember/optional-features": "2.0.0",
45
45
  "@ember/test-helpers": "2.6.0",
46
- "@embroider/test-setup": "1.1.0",
47
- "@faker-js/faker": "6.0.0-alpha.5",
48
- "@projectcaluma/ember-testing": "11.0.0-beta.2",
46
+ "@embroider/test-setup": "1.2.0",
47
+ "@faker-js/faker": "6.0.0-alpha.6",
48
+ "@projectcaluma/ember-testing": "11.0.0-beta.3",
49
49
  "@projectcaluma/ember-workflow": "11.0.0-beta.4",
50
50
  "broccoli-asset-rev": "3.0.0",
51
51
  "ember-cli": "3.28.5",
@@ -70,7 +70,7 @@
70
70
  "qunit": "2.17.2",
71
71
  "qunit-dom": "2.0.0",
72
72
  "uuid": "8.3.2",
73
- "webpack": "5.68.0"
73
+ "webpack": "5.69.0"
74
74
  },
75
75
  "engines": {
76
76
  "node": "12.* || 14.* || >= 16"