@projectcaluma/ember-form-builder 9.1.0 → 10.0.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.
Files changed (50) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/addon/components/cfb-form-editor/question/validation.js +1 -1
  3. package/addon/components/cfb-form-editor/question.hbs +34 -24
  4. package/addon/gql/mutations/add-form-question.graphql +2 -2
  5. package/addon/gql/mutations/remove-form-question.graphql +2 -2
  6. package/addon/gql/mutations/reorder-form-questions.graphql +2 -2
  7. package/addon/gql/mutations/save-action-button-question.graphql +1 -1
  8. package/addon/gql/mutations/save-calculated-float-question.graphql +1 -1
  9. package/addon/gql/mutations/save-choice-question.graphql +1 -1
  10. package/addon/gql/mutations/save-date-question.graphql +1 -1
  11. package/addon/gql/mutations/save-default-date-answer.graphql +2 -6
  12. package/addon/gql/mutations/save-default-float-answer.graphql +2 -6
  13. package/addon/gql/mutations/save-default-integer-answer.graphql +2 -6
  14. package/addon/gql/mutations/save-default-list-answer.graphql +2 -6
  15. package/addon/gql/mutations/save-default-string-answer.graphql +2 -6
  16. package/addon/gql/mutations/save-default-table-answer.graphql +2 -6
  17. package/addon/gql/mutations/save-dynamic-choice-question.graphql +1 -1
  18. package/addon/gql/mutations/save-dynamic-multiple-choice-question.graphql +1 -1
  19. package/addon/gql/mutations/save-file-question.graphql +1 -1
  20. package/addon/gql/mutations/save-float-question.graphql +1 -1
  21. package/addon/gql/mutations/save-form-question.graphql +1 -1
  22. package/addon/gql/mutations/save-form.graphql +1 -1
  23. package/addon/gql/mutations/save-integer-question.graphql +1 -1
  24. package/addon/gql/mutations/save-multiple-choice-question.graphql +1 -1
  25. package/addon/gql/mutations/save-static-question.graphql +1 -1
  26. package/addon/gql/mutations/save-table-question.graphql +1 -1
  27. package/addon/gql/mutations/save-text-question.graphql +1 -1
  28. package/addon/gql/mutations/save-textarea-question.graphql +1 -1
  29. package/addon/gql/queries/form-editor-general.graphql +1 -1
  30. package/addon/gql/queries/form-editor-question.graphql +2 -3
  31. package/addon/gql/queries/form-list.graphql +1 -1
  32. package/addon/gql/queries/search-form-question.graphql +1 -1
  33. package/addon/gql/queries/search-question.graphql +1 -1
  34. package/addon/routes/edit/questions/edit.js +1 -1
  35. package/addon/routes/edit.js +1 -1
  36. package/package.json +8 -8
  37. package/translations/de.yaml +1 -0
  38. package/translations/en.yaml +1 -0
  39. package/addon/gql/fragments/field-answer.graphql +0 -57
  40. package/addon/gql/fragments/field-question.graphql +0 -164
  41. package/addon/gql/mutations/archive-form.graphql +0 -5
  42. package/addon/gql/mutations/remove-document.graphql +0 -5
  43. package/addon/gql/queries/all-format-validators.graphql +0 -12
  44. package/addon/gql/queries/all-work-items.graphql +0 -9
  45. package/addon/gql/queries/data-source.graphql +0 -10
  46. package/addon/gql/queries/get-document-answers.graphql +0 -21
  47. package/addon/gql/queries/get-document-forms.graphql +0 -20
  48. package/addon/gql/queries/get-document-used-dynamic-options.graphql +0 -12
  49. package/addon/gql/queries/get-dynamic-options.graphql +0 -29
  50. package/addon/gql/queries/get-fileanswer-info.graphql +0 -13
package/CHANGELOG.md ADDED
@@ -0,0 +1,16 @@
1
+ # [@projectcaluma/ember-form-builder-v10.0.0](https://github.com/projectcaluma/ember-caluma/compare/@projectcaluma/ember-form-builder-v9.1.0...@projectcaluma/ember-form-builder-v10.0.0) (2021-11-25)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **action-button:** hide unnecessary field and improve naming of confirm text ([b722d96](https://github.com/projectcaluma/ember-caluma/commit/b722d9605407bd79bcebfc3f9d3bbefa846841e2))
7
+
8
+
9
+ ### chore
10
+
11
+ * **deps:** update dependencies and drop support for node 10 ([51d6dee](https://github.com/projectcaluma/ember-caluma/commit/51d6deeda9811518622ba0cefd8d3876651dab4f))
12
+
13
+
14
+ ### BREAKING CHANGES
15
+
16
+ * **deps:** Remove support for node v10
@@ -3,7 +3,7 @@ import Component from "@glimmer/component";
3
3
  import { queryManager } from "ember-apollo-client";
4
4
  import { dropTask } from "ember-concurrency";
5
5
 
6
- import allFormatValidatorsQuery from "@projectcaluma/ember-form-builder/gql/queries/all-format-validators.graphql";
6
+ import allFormatValidatorsQuery from "@projectcaluma/ember-core/gql/queries/all-format-validators.graphql";
7
7
 
8
8
  export default class CfbFormEditorQuestionValidation extends Component {
9
9
  @queryManager apollo;
@@ -136,25 +136,33 @@
136
136
  </div>
137
137
  {{/if}}
138
138
 
139
- <div class="uk-margin">
139
+ {{#if (has-question-type f.model "action-button")}}
140
140
  <f.input
141
- @label={{t "caluma.form-builder.question.infoText"}}
141
+ @label={{t "caluma.form-builder.question.confirmationText"}}
142
142
  @name="infoText"
143
- @renderComponent={{component
144
- "cfb-code-editor"
145
- language="markdown"
146
- className="uk-margin-remove-bottom"
147
- }}
143
+ @type="textarea"
148
144
  />
149
- <small class="uk-text-muted">
150
- {{t "caluma.form-builder.question.supportsMarkdownPrefix"}}
151
- <a
152
- target="_blank"
153
- rel="noopener noreferrer"
154
- href="https://www.markdownguide.org/basic-syntax"
155
- >{{t "caluma.form-builder.question.markdown"}}</a>
156
- </small>
157
- </div>
145
+ {{else}}
146
+ <div class="uk-margin">
147
+ <f.input
148
+ @label={{t "caluma.form-builder.question.infoText"}}
149
+ @name="infoText"
150
+ @renderComponent={{component
151
+ "cfb-code-editor"
152
+ language="markdown"
153
+ className="uk-margin-remove-bottom"
154
+ }}
155
+ />
156
+ <small class="uk-text-muted">
157
+ {{t "caluma.form-builder.question.supportsMarkdownPrefix"}}
158
+ <a
159
+ target="_blank"
160
+ rel="noopener noreferrer"
161
+ href="https://www.markdownguide.org/basic-syntax"
162
+ >{{t "caluma.form-builder.question.markdown"}}</a>
163
+ </small>
164
+ </div>
165
+ {{/if}}
158
166
 
159
167
  {{#if (has-question-type f.model "text" "textarea" "integer" "float")}}
160
168
  <f.input
@@ -295,14 +303,16 @@
295
303
  />
296
304
  {{/if}}
297
305
 
298
- <f.input
299
- @name="meta.hideLabel"
300
- @required={{true}}
301
- @label={{t "caluma.form-builder.question.hideLabel"}}
302
- @renderComponent={{component "cfb-toggle-switch" size="small"}}
303
- @on-update={{changeset-set f.model "meta.hideLabel"}}
304
- @value={{changeset-get f.model "meta.hideLabel"}}
305
- />
306
+ {{#if (not (has-question-type f.model "action-button"))}}
307
+ <f.input
308
+ @name="meta.hideLabel"
309
+ @required={{true}}
310
+ @label={{t "caluma.form-builder.question.hideLabel"}}
311
+ @renderComponent={{component "cfb-toggle-switch" size="small"}}
312
+ @on-update={{changeset-set f.model "meta.hideLabel"}}
313
+ @value={{changeset-get f.model "meta.hideLabel"}}
314
+ />
315
+ {{/if}}
306
316
 
307
317
  {{#if (has-question-type f.model "table")}}
308
318
  <div class="uk-margin">
@@ -1,5 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
2
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
+ #import QuestionInfo from '../fragments/question-info.graphql'
3
3
 
4
4
  mutation AddFormQuestion($input: AddFormQuestionInput!, $search: String) {
5
5
  addFormQuestion(input: $input) {
@@ -1,5 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
2
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
+ #import QuestionInfo from '../fragments/question-info.graphql'
3
3
 
4
4
  mutation RemoveFormQuestion($input: RemoveFormQuestionInput!, $search: String) {
5
5
  removeFormQuestion(input: $input) {
@@ -1,5 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
2
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
+ #import QuestionInfo from '../fragments/question-info.graphql'
3
3
 
4
4
  mutation ReorderFormQuestions(
5
5
  $input: ReorderFormQuestionsInput!
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveActionButtonQuestion($input: SaveActionButtonQuestionInput!) {
4
4
  saveActionButtonQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveCalculatedFloatQuestion(
4
4
  $input: SaveCalculatedFloatQuestionInput!
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveChoiceQuestion($input: SaveChoiceQuestionInput!) {
4
4
  saveChoiceQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveDateQuestion($input: SaveDateQuestionInput!) {
4
4
  saveDateQuestion(input: $input) {
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultDateAnswerInput!) {
1
+ mutation SaveDefaultDateAnswer($input: SaveDefaultDateAnswerInput!) {
4
2
  saveDefaultDateAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultFloatAnswerInput!) {
1
+ mutation SaveDefaultFloatAnswer($input: SaveDefaultFloatAnswerInput!) {
4
2
  saveDefaultFloatAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultIntegerAnswerInput!) {
1
+ mutation SaveDefaultIntegerAnswer($input: SaveDefaultIntegerAnswerInput!) {
4
2
  saveDefaultIntegerAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultListAnswerInput!) {
1
+ mutation SaveDefaultListAnswer($input: SaveDefaultListAnswerInput!) {
4
2
  saveDefaultListAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultStringAnswerInput!) {
1
+ mutation SaveDefaultStringAnswer($input: SaveDefaultStringAnswerInput!) {
4
2
  saveDefaultStringAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,9 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- mutation ($input: SaveDefaultTableAnswerInput!) {
1
+ mutation SaveDefaultTableAnswer($input: SaveDefaultTableAnswerInput!) {
4
2
  saveDefaultTableAnswer(input: $input) {
5
- answer {
6
- ...FieldAnswer
7
- }
3
+ clientMutationId
8
4
  }
9
5
  }
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveDynamicChoiceQuestion($input: SaveDynamicChoiceQuestionInput!) {
4
4
  saveDynamicChoiceQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveDynamicMultipleChoiceQuestion(
4
4
  $input: SaveDynamicMultipleChoiceQuestionInput!
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveFileQuestion($input: SaveFileQuestionInput!) {
4
4
  saveFileQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveFloatQuestion($input: SaveFloatQuestionInput!) {
4
4
  saveFloatQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveFormQuestion($input: SaveFormQuestionInput!) {
4
4
  saveFormQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
2
 
3
3
  mutation SaveForm($input: SaveFormInput!) {
4
4
  saveForm(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveIntegerQuestion($input: SaveIntegerQuestionInput!) {
4
4
  saveIntegerQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveMultipleChoiceQuestion($input: SaveMultipleChoiceQuestionInput!) {
4
4
  saveMultipleChoiceQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveStaticQuestion($input: SaveStaticQuestionInput!) {
4
4
  saveStaticQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveTableQuestion($input: SaveTableQuestionInput!) {
4
4
  saveTableQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveTextQuestion($input: SaveTextQuestionInput!) {
4
4
  saveTextQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  mutation SaveTextareaQuestion($input: SaveTextareaQuestionInput!) {
4
4
  saveTextareaQuestion(input: $input) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
2
 
3
3
  query FormEditorGeneral($slug: String!) {
4
4
  allForms(filter: [{ slug: $slug }]) {
@@ -1,6 +1,5 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
2
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-question.graphql'
3
- # import SimpleAnswer from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
+ #import FieldQuestion, FieldTableQuestion, SimpleAnswer, SimpleQuestion from '../fragments/field.graphql'
4
3
 
5
4
  query FormEditorQuestion($slug: String!) {
6
5
  allQuestions(filter: [{ slug: $slug }]) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/form-info.graphql'
1
+ #import FormInfo from '../fragments/form-info.graphql'
2
2
 
3
3
  query FormList($filter: [FormFilterSetType], $order: [FormOrderSetType]) {
4
4
  allForms(filter: $filter, order: $order) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  query SearchFormQuestion($slug: String!, $search: String, $archived: Boolean) {
4
4
  allForms(filter: [{ slug: $slug }]) {
@@ -1,4 +1,4 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/question-info.graphql'
1
+ #import QuestionInfo from '../fragments/question-info.graphql'
2
2
 
3
3
  query SearchQuestion(
4
4
  $search: String
@@ -2,7 +2,7 @@ import Route from "@ember/routing/route";
2
2
  import { inject as service } from "@ember/service";
3
3
  import { queryManager } from "ember-apollo-client";
4
4
  import { lastValue, dropTask } from "ember-concurrency-decorators";
5
- import gql from "graphql-tag";
5
+ import { gql } from "graphql-tag";
6
6
 
7
7
  import { navigationTitle } from "@projectcaluma/ember-form-builder/decorators";
8
8
 
@@ -2,7 +2,7 @@ import Route from "@ember/routing/route";
2
2
  import { inject as service } from "@ember/service";
3
3
  import { queryManager } from "ember-apollo-client";
4
4
  import { lastValue, dropTask } from "ember-concurrency-decorators";
5
- import gql from "graphql-tag";
5
+ import { gql } from "graphql-tag";
6
6
 
7
7
  import { navigationTitle } from "@projectcaluma/ember-form-builder/decorators";
8
8
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@projectcaluma/ember-form-builder",
3
- "version": "9.1.0",
3
+ "version": "10.0.0",
4
4
  "description": "Ember engine for building Caluma forms.",
5
5
  "keywords": [
6
6
  "ember-addon",
@@ -18,8 +18,8 @@
18
18
  "@ember/render-modifiers": "^2.0.0",
19
19
  "@glimmer/component": "^1.0.4",
20
20
  "@glimmer/tracking": "^1.0.4",
21
- "@projectcaluma/ember-core": "9.2.0",
22
- "@projectcaluma/ember-form": "9.3.0",
21
+ "@projectcaluma/ember-core": "^10.0.0",
22
+ "@projectcaluma/ember-form": "^10.0.0",
23
23
  "codejar": "^3.5.0",
24
24
  "ember-apollo-client": "^3.2.0",
25
25
  "ember-auto-import": "^2.2.3",
@@ -34,7 +34,7 @@
34
34
  "ember-fetch": "^8.0.4",
35
35
  "ember-math-helpers": "^2.18.0",
36
36
  "ember-pikaday": "^3.0.0",
37
- "ember-power-select": "^4.1.6",
37
+ "ember-power-select": "^4.1.7",
38
38
  "ember-test-selectors": "^6.0.0",
39
39
  "ember-uikit": "^4.0.0",
40
40
  "ember-validated-form": "^5.0.0",
@@ -48,9 +48,9 @@
48
48
  "@ember/optional-features": "2.0.0",
49
49
  "@ember/test-helpers": "2.6.0",
50
50
  "@embroider/test-setup": "0.47.2",
51
- "@projectcaluma/ember-testing": "9.0.0",
51
+ "@projectcaluma/ember-testing": "9.1.0",
52
52
  "broccoli-asset-rev": "3.0.0",
53
- "ember-cli": "3.28.3",
53
+ "ember-cli": "3.28.4",
54
54
  "ember-cli-code-coverage": "1.0.3",
55
55
  "ember-cli-dependency-checker": "3.2.0",
56
56
  "ember-cli-inject-live-reload": "2.1.0",
@@ -73,10 +73,10 @@
73
73
  "npm-run-all": "4.1.5",
74
74
  "qunit": "2.17.2",
75
75
  "qunit-dom": "2.0.0",
76
- "webpack": "5.64.0"
76
+ "webpack": "5.64.1"
77
77
  },
78
78
  "engines": {
79
- "node": "10.* || >= 12"
79
+ "node": "12.* || 14.* || >= 16"
80
80
  },
81
81
  "ember": {
82
82
  "edition": "octane"
@@ -52,6 +52,7 @@ caluma:
52
52
  isRequired: "Pflichtfeld"
53
53
  staticContent: "Statischer Inhalt"
54
54
  infoText: "Infotext"
55
+ confirmationText: "Bestätigungstext"
55
56
  placeholder: "Platzhalter"
56
57
  isHidden: "Versteckt (JEXL)"
57
58
  widgetOverride: "Anzeigetyp"
@@ -52,6 +52,7 @@ caluma:
52
52
  isRequired: "Required"
53
53
  staticContent: "Static content"
54
54
  infoText: "Information text"
55
+ confirmationText: "Confirmation text"
55
56
  placeholder: "Placeholder"
56
57
  isHidden: "Hidden (JEXL)"
57
58
  widgetOverride: "Widget type"
@@ -1,57 +0,0 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-question.graphql'
2
-
3
- fragment SimpleAnswer on Answer {
4
- id
5
- question {
6
- slug
7
- }
8
- ... on StringAnswer {
9
- stringValue: value
10
- }
11
- ... on IntegerAnswer {
12
- integerValue: value
13
- }
14
- ... on FloatAnswer {
15
- floatValue: value
16
- }
17
- ... on ListAnswer {
18
- listValue: value
19
- }
20
- ... on FileAnswer {
21
- fileValue: value {
22
- uploadUrl
23
- downloadUrl
24
- metadata
25
- name
26
- }
27
- }
28
- ... on DateAnswer {
29
- dateValue: value
30
- }
31
- }
32
-
33
- fragment FieldAnswer on Answer {
34
- ...SimpleAnswer
35
- ... on TableAnswer {
36
- tableValue: value {
37
- id
38
- form {
39
- slug
40
- questions {
41
- edges {
42
- node {
43
- ...FieldQuestion
44
- }
45
- }
46
- }
47
- }
48
- answers {
49
- edges {
50
- node {
51
- ...SimpleAnswer
52
- }
53
- }
54
- }
55
- }
56
- }
57
- }
@@ -1,164 +0,0 @@
1
- fragment SimpleQuestion on Question {
2
- slug
3
- label
4
- isRequired
5
- isHidden
6
- meta
7
- infoText
8
- ... on TextQuestion {
9
- textMinLength: minLength
10
- textMaxLength: maxLength
11
- textDefaultAnswer: defaultAnswer {
12
- value
13
- }
14
- placeholder
15
- }
16
- ... on TextareaQuestion {
17
- textareaMinLength: minLength
18
- textareaMaxLength: maxLength
19
- textareaDefaultAnswer: defaultAnswer {
20
- value
21
- }
22
- placeholder
23
- }
24
- ... on IntegerQuestion {
25
- integerMinValue: minValue
26
- integerMaxValue: maxValue
27
- integerDefaultAnswer: defaultAnswer {
28
- value
29
- }
30
- placeholder
31
- }
32
- ... on FloatQuestion {
33
- floatMinValue: minValue
34
- floatMaxValue: maxValue
35
- floatDefaultAnswer: defaultAnswer {
36
- value
37
- }
38
- placeholder
39
- }
40
- ... on ChoiceQuestion {
41
- choiceOptions: options {
42
- edges {
43
- node {
44
- slug
45
- label
46
- isArchived
47
- }
48
- }
49
- }
50
- choiceDefaultAnswer: defaultAnswer {
51
- value
52
- }
53
- }
54
- ... on MultipleChoiceQuestion {
55
- multipleChoiceOptions: options {
56
- edges {
57
- node {
58
- slug
59
- label
60
- isArchived
61
- }
62
- }
63
- }
64
- multipleChoiceDefaultAnswer: defaultAnswer {
65
- value
66
- }
67
- }
68
- ... on DateQuestion {
69
- dateDefaultAnswer: defaultAnswer {
70
- value
71
- }
72
- }
73
- ... on StaticQuestion {
74
- staticContent
75
- }
76
- ... on CalculatedFloatQuestion {
77
- calcExpression
78
- }
79
- ... on ActionButtonQuestion {
80
- action
81
- color
82
- validateOnEnter
83
- }
84
- }
85
-
86
- fragment FieldTableQuestion on Question {
87
- ... on TableQuestion {
88
- rowForm {
89
- slug
90
- questions {
91
- edges {
92
- node {
93
- ...SimpleQuestion
94
- }
95
- }
96
- }
97
- }
98
- tableDefaultAnswer: defaultAnswer {
99
- value {
100
- id
101
- answers {
102
- edges {
103
- node {
104
- id
105
- question {
106
- slug
107
- }
108
- ... on StringAnswer {
109
- stringValue: value
110
- }
111
- ... on IntegerAnswer {
112
- integerValue: value
113
- }
114
- ... on FloatAnswer {
115
- floatValue: value
116
- }
117
- ... on ListAnswer {
118
- listValue: value
119
- }
120
- ... on DateAnswer {
121
- dateValue: value
122
- }
123
- }
124
- }
125
- }
126
- }
127
- }
128
- }
129
- }
130
-
131
- fragment FieldQuestion on Question {
132
- ...SimpleQuestion
133
- ...FieldTableQuestion
134
- ... on FormQuestion {
135
- subForm {
136
- slug
137
- name
138
- questions {
139
- edges {
140
- node {
141
- # This part here limits our query to 2 level deep nested forms. This
142
- # has to be solved in another way!
143
- ...SimpleQuestion
144
- ...FieldTableQuestion
145
- ... on FormQuestion {
146
- subForm {
147
- slug
148
- name
149
- questions {
150
- edges {
151
- node {
152
- ...SimpleQuestion
153
- ...FieldTableQuestion
154
- }
155
- }
156
- }
157
- }
158
- }
159
- }
160
- }
161
- }
162
- }
163
- }
164
- }
@@ -1,5 +0,0 @@
1
- mutation ArchiveForm($input: ArchiveFormInput!) {
2
- archiveForm(input: $input) {
3
- clientMutationId
4
- }
5
- }
@@ -1,5 +0,0 @@
1
- mutation RemoveDocument($input: RemoveDocumentInput!) {
2
- removeDocument(input: $input) {
3
- clientMutationId
4
- }
5
- }
@@ -1,12 +0,0 @@
1
- query AllFormatValidators {
2
- allFormatValidators {
3
- edges {
4
- node {
5
- slug
6
- name
7
- regex
8
- errorMsg
9
- }
10
- }
11
- }
12
- }
@@ -1,9 +0,0 @@
1
- query AllWorkItems($filter: [WorkItemFilterSetType]!) {
2
- allWorkItems(filter: $filter) {
3
- edges {
4
- node {
5
- id
6
- }
7
- }
8
- }
9
- }
@@ -1,10 +0,0 @@
1
- query DataSource($name: String!) {
2
- dataSource(filter: [{ name: $name }]) {
3
- edges {
4
- node {
5
- label
6
- slug
7
- }
8
- }
9
- }
10
- }
@@ -1,21 +0,0 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-answer.graphql'
2
-
3
- query ($id: ID!) {
4
- allDocuments(filter: [{ id: $id }]) {
5
- edges {
6
- node {
7
- id
8
- form {
9
- slug
10
- }
11
- answers {
12
- edges {
13
- node {
14
- ...FieldAnswer
15
- }
16
- }
17
- }
18
- }
19
- }
20
- }
21
- }
@@ -1,20 +0,0 @@
1
- # import * from '@projectcaluma/ember-form-builder/gql/fragments/field-question.graphql'
2
-
3
- query ($slug: String!) {
4
- allForms(filter: [{ slug: $slug }]) {
5
- edges {
6
- node {
7
- slug
8
- name
9
- meta
10
- questions {
11
- edges {
12
- node {
13
- ...FieldQuestion
14
- }
15
- }
16
- }
17
- }
18
- }
19
- }
20
- }
@@ -1,12 +0,0 @@
1
- query GetDocumentUsedDynamicOptions($document: ID!, $question: ID!) {
2
- allUsedDynamicOptions(
3
- filter: [{ document: $document }, { question: $question }]
4
- ) {
5
- edges {
6
- node {
7
- slug
8
- label
9
- }
10
- }
11
- }
12
- }
@@ -1,29 +0,0 @@
1
- query ($question: String!) {
2
- allQuestions(filter: [{ slug: $question }], first: 1) {
3
- edges {
4
- node {
5
- slug
6
- ... on DynamicChoiceQuestion {
7
- dynamicChoiceOptions: options {
8
- edges {
9
- node {
10
- slug
11
- label
12
- }
13
- }
14
- }
15
- }
16
- ... on DynamicMultipleChoiceQuestion {
17
- dynamicMultipleChoiceOptions: options {
18
- edges {
19
- node {
20
- slug
21
- label
22
- }
23
- }
24
- }
25
- }
26
- }
27
- }
28
- }
29
- }
@@ -1,13 +0,0 @@
1
- query getFileAnswerInfo($id: ID!) {
2
- node(id: $id) {
3
- id
4
- ... on FileAnswer {
5
- fileValue: value {
6
- uploadUrl
7
- downloadUrl
8
- metadata
9
- name
10
- }
11
- }
12
- }
13
- }