@operato/app 1.0.0-beta.9 → 1.0.2

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 (102) hide show
  1. package/CHANGELOG.md +379 -0
  2. package/demo/data-grist-test.html +1 -1
  3. package/dist/src/filters-form/filter-resource-select.d.ts +4 -0
  4. package/dist/src/filters-form/filter-resource-select.js +78 -0
  5. package/dist/src/filters-form/filter-resource-select.js.map +1 -0
  6. package/dist/src/filters-form/index.d.ts +1 -0
  7. package/dist/src/filters-form/index.js +5 -0
  8. package/dist/src/filters-form/index.js.map +1 -0
  9. package/dist/src/grist-editor/index.js +1 -9
  10. package/dist/src/grist-editor/index.js.map +1 -1
  11. package/dist/src/grist-editor/ox-grist-editor-resource-object-legacy.d.ts +10 -0
  12. package/dist/src/grist-editor/ox-grist-editor-resource-object-legacy.js +99 -0
  13. package/dist/src/grist-editor/ox-grist-editor-resource-object-legacy.js.map +1 -0
  14. package/dist/src/grist-editor/ox-grist-editor-resource-object.d.ts +0 -1
  15. package/dist/src/grist-editor/ox-grist-editor-resource-object.js +10 -13
  16. package/dist/src/grist-editor/ox-grist-editor-resource-object.js.map +1 -1
  17. package/dist/src/grist-editor/ox-grist-renderer-crontab.js +3 -3
  18. package/dist/src/grist-editor/ox-grist-renderer-crontab.js.map +1 -1
  19. package/dist/src/grist-editor/ox-grist-renderer-resource-id.js +5 -2
  20. package/dist/src/grist-editor/ox-grist-renderer-resource-id.js.map +1 -1
  21. package/dist/src/grist-editor/ox-popup-code-input.js +5 -4
  22. package/dist/src/grist-editor/ox-popup-code-input.js.map +1 -1
  23. package/dist/src/grist-editor/ox-selector-resource-id.js +5 -4
  24. package/dist/src/grist-editor/ox-selector-resource-id.js.map +1 -1
  25. package/dist/src/grist-editor/ox-selector-resource-object-adv.d.ts +36 -0
  26. package/dist/src/grist-editor/ox-selector-resource-object-adv.js +270 -0
  27. package/dist/src/grist-editor/ox-selector-resource-object-adv.js.map +1 -0
  28. package/dist/src/grist-editor/ox-selector-resource-object-legacy.d.ts +39 -0
  29. package/dist/src/grist-editor/ox-selector-resource-object-legacy.js +351 -0
  30. package/dist/src/grist-editor/ox-selector-resource-object-legacy.js.map +1 -0
  31. package/dist/src/grist-editor/ox-selector-resource-object.d.ts +3 -8
  32. package/dist/src/grist-editor/ox-selector-resource-object.js +76 -152
  33. package/dist/src/grist-editor/ox-selector-resource-object.js.map +1 -1
  34. package/dist/src/input/ox-input-background-pattern.d.ts +3 -0
  35. package/dist/src/input/ox-input-background-pattern.js +35 -7
  36. package/dist/src/input/ox-input-background-pattern.js.map +1 -1
  37. package/dist/src/input/ox-input-fill-style.d.ts +4 -2
  38. package/dist/src/input/ox-input-fill-style.js +13 -7
  39. package/dist/src/input/ox-input-fill-style.js.map +1 -1
  40. package/dist/src/input/ox-input-graphql.d.ts +1 -1
  41. package/dist/src/input/ox-input-graphql.js +7 -7
  42. package/dist/src/input/ox-input-graphql.js.map +1 -1
  43. package/dist/src/property-editor/index.d.ts +2 -1
  44. package/dist/src/property-editor/index.js +5 -2
  45. package/dist/src/property-editor/index.js.map +1 -1
  46. package/dist/src/property-editor/ox-property-editor-graphql.d.ts +2 -2
  47. package/dist/src/property-editor/ox-property-editor-graphql.js +4 -4
  48. package/dist/src/property-editor/ox-property-editor-graphql.js.map +1 -1
  49. package/dist/tsconfig.tsbuildinfo +1 -1
  50. package/package.json +25 -30
  51. package/src/filters-form/filter-resource-select.ts +94 -0
  52. package/src/filters-form/index.ts +6 -0
  53. package/src/grist-editor/index.ts +1 -9
  54. package/src/grist-editor/ox-grist-editor-resource-object-legacy.ts +123 -0
  55. package/src/grist-editor/ox-grist-editor-resource-object.ts +22 -14
  56. package/src/grist-editor/ox-grist-renderer-crontab.ts +5 -4
  57. package/src/grist-editor/ox-grist-renderer-resource-id.ts +6 -2
  58. package/src/grist-editor/ox-popup-code-input.ts +5 -4
  59. package/src/grist-editor/ox-selector-resource-id.ts +5 -4
  60. package/src/grist-editor/ox-selector-resource-object-legacy.ts +360 -0
  61. package/src/grist-editor/ox-selector-resource-object.ts +76 -166
  62. package/src/input/ox-input-background-pattern.ts +37 -7
  63. package/src/input/ox-input-fill-style.ts +18 -8
  64. package/src/input/ox-input-graphql.ts +8 -8
  65. package/src/property-editor/index.ts +5 -2
  66. package/src/property-editor/ox-property-editor-graphql.ts +5 -4
  67. package/dist/src/grist-editor/ox-grist-editor-crontab.d.ts +0 -8
  68. package/dist/src/grist-editor/ox-grist-editor-crontab.js +0 -50
  69. package/dist/src/grist-editor/ox-grist-editor-crontab.js.map +0 -1
  70. package/dist/src/grist-editor/ox-grist-editor-parameters.d.ts +0 -12
  71. package/dist/src/grist-editor/ox-grist-editor-parameters.js +0 -84
  72. package/dist/src/grist-editor/ox-grist-editor-parameters.js.map +0 -1
  73. package/dist/src/grist-editor/ox-grist-editor-partition-keys.d.ts +0 -11
  74. package/dist/src/grist-editor/ox-grist-editor-partition-keys.js +0 -74
  75. package/dist/src/grist-editor/ox-grist-editor-partition-keys.js.map +0 -1
  76. package/dist/src/grist-editor/ox-grist-editor-value-map.d.ts +0 -11
  77. package/dist/src/grist-editor/ox-grist-editor-value-map.js +0 -74
  78. package/dist/src/grist-editor/ox-grist-editor-value-map.js.map +0 -1
  79. package/dist/src/grist-editor/ox-parameters-builder.d.ts +0 -4
  80. package/dist/src/grist-editor/ox-parameters-builder.js +0 -118
  81. package/dist/src/grist-editor/ox-parameters-builder.js.map +0 -1
  82. package/dist/src/grist-editor/ox-popup-crontab-input.d.ts +0 -11
  83. package/dist/src/grist-editor/ox-popup-crontab-input.js +0 -74
  84. package/dist/src/grist-editor/ox-popup-crontab-input.js.map +0 -1
  85. package/dist/src/grist-editor/ox-popup-parameters-builder.d.ts +0 -13
  86. package/dist/src/grist-editor/ox-popup-parameters-builder.js +0 -111
  87. package/dist/src/grist-editor/ox-popup-parameters-builder.js.map +0 -1
  88. package/dist/src/grist-editor/ox-popup-partition-keys-input.d.ts +0 -12
  89. package/dist/src/grist-editor/ox-popup-partition-keys-input.js +0 -98
  90. package/dist/src/grist-editor/ox-popup-partition-keys-input.js.map +0 -1
  91. package/dist/src/grist-editor/ox-popup-value-map-input.d.ts +0 -12
  92. package/dist/src/grist-editor/ox-popup-value-map-input.js +0 -104
  93. package/dist/src/grist-editor/ox-popup-value-map-input.js.map +0 -1
  94. package/src/grist-editor/ox-grist-editor-crontab.ts +0 -62
  95. package/src/grist-editor/ox-grist-editor-parameters.ts +0 -99
  96. package/src/grist-editor/ox-grist-editor-partition-keys.ts +0 -86
  97. package/src/grist-editor/ox-grist-editor-value-map.ts +0 -86
  98. package/src/grist-editor/ox-parameters-builder.ts +0 -128
  99. package/src/grist-editor/ox-popup-crontab-input.ts +0 -74
  100. package/src/grist-editor/ox-popup-parameters-builder.ts +0 -106
  101. package/src/grist-editor/ox-popup-partition-keys-input.ts +0 -95
  102. package/src/grist-editor/ox-popup-value-map-input.ts +0 -101
@@ -1,95 +0,0 @@
1
- import '@operato/input/ox-input-partition-keys.js'
2
-
3
- import { LitElement, css, html } from 'lit'
4
- import { customElement, property } from 'lit/decorators.js'
5
-
6
- import { ScrollbarStyles } from '@operato/styles'
7
- import { i18next } from '@operato/i18n'
8
-
9
- @customElement('ox-popup-partition-keys-input')
10
- export class OxPopupPartitionKeysInput extends LitElement {
11
- static styles = [
12
- ScrollbarStyles,
13
- css`
14
- :host {
15
- display: flex;
16
- flex-direction: column;
17
-
18
- background-color: #fff;
19
-
20
- width: var(--overlay-center-normal-width, 50%);
21
- height: var(--overlay-center-normal-height, 50%);
22
- }
23
-
24
- ox-input-partition-keys {
25
- flex: 1;
26
- overflow-y: auto;
27
- }
28
-
29
- span {
30
- flex: 1;
31
-
32
- display: flex;
33
- align-items: center;
34
- justify-content: center;
35
-
36
- color: var(--primary-color);
37
- }
38
-
39
- .button-container {
40
- display: flex;
41
- margin-left: auto;
42
- }
43
- `
44
- ]
45
-
46
- @property({ type: Object }) value: any
47
- @property({ type: String }) valuetype: string = 'string'
48
- @property({ type: Object }) confirmCallback!: (newval: any) => void
49
-
50
- render() {
51
- return html`
52
- <ox-input-partition-keys .value=${this.value} @change=${this.onChange.bind(this)}> </ox-input-partition-keys>
53
-
54
- <div class="button-container">
55
- <mwc-button @click=${this.onCancel.bind(this)}>${i18next.t('button.cancel')}</mwc-button>
56
- <mwc-button @click=${this.onConfirm.bind(this)}>${i18next.t('button.confirm')}</mwc-button>
57
- </div>
58
- `
59
- }
60
-
61
- private onChange(e: CustomEvent) {
62
- e.stopPropagation()
63
-
64
- /*
65
- 주의 : 이 팝업 템플릿은 layout 모듈에 의해서 render 되므로,
66
- layout의 구성에 변화가 발생하면, 다시 render된다.
67
- 이 팝업이 떠 있는 상태에서, 또 다른 팝업이 뜨는 경우도 layout 구성의 변화를 야기한다. (overlay의 갯수의 증가)
68
- 이 경우 value, options, confirmCallback 등 클로져를 사용한 것들이 초기 바인딩된 값으로 다시 바인딩되게 되는데,
69
- 만약, 템플릿 내부에서 이들 속성의 레퍼런스가 변화했다면, 원래 상태로 되돌아가는 현상이 발생하게 된다.
70
- 따라서, 가급적 이들 속성의 레퍼런스를 변화시키지 않는 것이 좋다.
71
- (이 팝업 클래스를 템플릿으로 사용한 곳의 코드를 참조하세요.)
72
- =>
73
- 이런 이유로, Object.assign(...)을 사용하였다.
74
- */
75
-
76
- if (!this.value || typeof this.value !== 'object') {
77
- this.value = {}
78
- }
79
-
80
- for (let key in this.value) {
81
- delete this.value[key]
82
- }
83
-
84
- Object.assign(this.value, e.detail)
85
- }
86
-
87
- private onCancel(e: Event) {
88
- history.back()
89
- }
90
-
91
- private onConfirm(e: Event) {
92
- this.confirmCallback && this.confirmCallback(this.value)
93
- history.back()
94
- }
95
- }
@@ -1,101 +0,0 @@
1
- import '@operato/input/ox-input-value-map.js'
2
-
3
- import { LitElement, css, html } from 'lit'
4
- import { customElement, property } from 'lit/decorators.js'
5
-
6
- import { ScrollbarStyles } from '@operato/styles'
7
- import { i18next } from '@operato/i18n'
8
-
9
- @customElement('ox-popup-value-map-input')
10
- export class OxPopupValueMapInput extends LitElement {
11
- static styles = [
12
- ScrollbarStyles,
13
- css`
14
- :host {
15
- display: flex;
16
- flex-direction: column;
17
-
18
- background-color: #fff;
19
-
20
- width: var(--overlay-center-normal-width, 50%);
21
- height: var(--overlay-center-normal-height, 50%);
22
- }
23
-
24
- ox-input-value-map {
25
- flex: 1;
26
- overflow-y: auto;
27
- }
28
-
29
- span {
30
- flex: 1;
31
-
32
- display: flex;
33
- align-items: center;
34
- justify-content: center;
35
-
36
- color: var(--primary-color);
37
- }
38
-
39
- .button-container {
40
- display: flex;
41
- margin-left: auto;
42
- }
43
- `
44
- ]
45
-
46
- @property({ type: Object }) value: any
47
- @property({ type: String }) valuetype: string = 'string'
48
- @property({ type: Object }) confirmCallback!: (newval: any) => void
49
-
50
- render() {
51
- return html`
52
- <ox-input-value-map
53
- .value=${this.value}
54
- keytype="string"
55
- .valuetype=${this.valuetype}
56
- @change=${this.onChange.bind(this)}
57
- >
58
- </ox-input-value-map>
59
-
60
- <div class="button-container">
61
- <mwc-button @click=${this.onCancel.bind(this)}>${i18next.t('button.cancel')}</mwc-button>
62
- <mwc-button @click=${this.onConfirm.bind(this)}>${i18next.t('button.confirm')}</mwc-button>
63
- </div>
64
- `
65
- }
66
-
67
- private onChange(e: CustomEvent) {
68
- e.stopPropagation()
69
-
70
- /*
71
- 주의 : 이 팝업 템플릿은 layout 모듈에 의해서 render 되므로,
72
- layout의 구성에 변화가 발생하면, 다시 render된다.
73
- 이 팝업이 떠 있는 상태에서, 또 다른 팝업이 뜨는 경우도 layout 구성의 변화를 야기한다. (overlay의 갯수의 증가)
74
- 이 경우 value, options, confirmCallback 등 클로져를 사용한 것들이 초기 바인딩된 값으로 다시 바인딩되게 되는데,
75
- 만약, 템플릿 내부에서 이들 속성의 레퍼런스가 변화했다면, 원래 상태로 되돌아가는 현상이 발생하게 된다.
76
- 따라서, 가급적 이들 속성의 레퍼런스를 변화시키지 않는 것이 좋다.
77
- (이 팝업 클래스를 템플릿으로 사용한 곳의 코드를 참조하세요.)
78
- =>
79
- 이런 이유로, Object.assign(...)을 사용하였다.
80
- */
81
-
82
- if (!this.value) {
83
- this.value = {}
84
- }
85
-
86
- for (let key in this.value) {
87
- delete this.value[key]
88
- }
89
-
90
- Object.assign(this.value, e.detail)
91
- }
92
-
93
- private onCancel(e: Event) {
94
- history.back()
95
- }
96
-
97
- private onConfirm(e: Event) {
98
- this.confirmCallback && this.confirmCallback(this.value)
99
- history.back()
100
- }
101
- }