@dxos/plugin-board 0.8.4-main.406dc2a → 0.8.4-main.43cb759274
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/LICENSE +102 -5
- package/PLUGIN.mdl +337 -0
- package/README.md +1 -1
- package/dist/lib/neutral/BoardArticle-XCMTXRNW.mjs +168 -0
- package/dist/lib/neutral/BoardArticle-XCMTXRNW.mjs.map +7 -0
- package/dist/lib/neutral/BoardPlugin.mjs +42 -0
- package/dist/lib/neutral/BoardPlugin.mjs.map +7 -0
- package/dist/lib/neutral/capabilities/index.mjs +11 -0
- package/dist/lib/neutral/capabilities/index.mjs.map +7 -0
- package/dist/lib/neutral/chunk-CY5X6YV4.mjs +34 -0
- package/dist/lib/neutral/chunk-CY5X6YV4.mjs.map +7 -0
- package/dist/lib/neutral/chunk-HUBZKCPA.mjs +32 -0
- package/dist/lib/neutral/chunk-HUBZKCPA.mjs.map +7 -0
- package/dist/lib/neutral/chunk-J5LGTIGS.mjs +10 -0
- package/dist/lib/neutral/components/index.mjs +1 -0
- package/dist/lib/neutral/containers/index.mjs +9 -0
- package/dist/lib/neutral/containers/index.mjs.map +7 -0
- package/dist/lib/neutral/create-object-BRISOU7F.mjs +28 -0
- package/dist/lib/neutral/create-object-BRISOU7F.mjs.map +7 -0
- package/dist/lib/neutral/index.mjs +12 -0
- package/dist/lib/neutral/index.mjs.map +7 -0
- package/dist/lib/neutral/meta.json +1 -0
- package/dist/lib/neutral/meta.mjs +8 -0
- package/dist/lib/neutral/meta.mjs.map +7 -0
- package/dist/lib/neutral/plugin.mjs +12 -0
- package/dist/lib/neutral/plugin.mjs.map +7 -0
- package/dist/lib/neutral/react-surface-M5JHK3ZQ.mjs +26 -0
- package/dist/lib/neutral/react-surface-M5JHK3ZQ.mjs.map +7 -0
- package/dist/lib/neutral/translations.mjs +30 -0
- package/dist/lib/neutral/translations.mjs.map +7 -0
- package/dist/lib/{browser → neutral}/types/index.mjs +2 -1
- package/dist/lib/neutral/types/index.mjs.map +7 -0
- package/dist/types/src/BoardPlugin.d.ts +3 -1
- package/dist/types/src/BoardPlugin.d.ts.map +1 -1
- package/dist/types/src/BoardPlugin.test.d.ts +2 -0
- package/dist/types/src/BoardPlugin.test.d.ts.map +1 -0
- package/dist/types/src/capabilities/create-object.d.ts +11 -0
- package/dist/types/src/capabilities/create-object.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +8 -2
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-surface.d.ts +3 -2
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +0 -1
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/containers/BoardArticle/BoardArticle.d.ts +6 -0
- package/dist/types/src/containers/BoardArticle/BoardArticle.d.ts.map +1 -0
- package/dist/types/src/containers/BoardArticle/BoardArticle.stories.d.ts +54 -0
- package/dist/types/src/containers/BoardArticle/BoardArticle.stories.d.ts.map +1 -0
- package/dist/types/src/containers/BoardArticle/index.d.ts +2 -0
- package/dist/types/src/containers/BoardArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/index.d.ts +3 -0
- package/dist/types/src/containers/index.d.ts.map +1 -0
- package/dist/types/src/index.d.ts +0 -2
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +2 -2
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/plugin.d.ts +3 -0
- package/dist/types/src/plugin.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +22 -13
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Board.d.ts +27 -70
- package/dist/types/src/types/Board.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +96 -59
- package/src/BoardPlugin.test.ts +27 -0
- package/src/BoardPlugin.tsx +21 -49
- package/src/capabilities/create-object.ts +31 -0
- package/src/capabilities/index.ts +3 -3
- package/src/capabilities/react-surface.tsx +23 -14
- package/src/components/index.ts +0 -2
- package/src/containers/BoardArticle/BoardArticle.stories.tsx +122 -0
- package/src/containers/BoardArticle/BoardArticle.tsx +186 -0
- package/src/containers/BoardArticle/index.ts +5 -0
- package/src/containers/index.ts +7 -0
- package/src/index.ts +0 -3
- package/src/meta.ts +20 -6
- package/src/plugin.ts +9 -0
- package/src/translations.ts +14 -11
- package/src/types/Board.ts +8 -24
- package/src/vite-env.d.ts +10 -0
- package/dist/lib/browser/chunk-RHMZXTJ7.mjs +0 -129
- package/dist/lib/browser/chunk-RHMZXTJ7.mjs.map +0 -7
- package/dist/lib/browser/chunk-Z6L4ZVCB.mjs +0 -59
- package/dist/lib/browser/chunk-Z6L4ZVCB.mjs.map +0 -7
- package/dist/lib/browser/index.mjs +0 -89
- package/dist/lib/browser/index.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-H6OF7V77.mjs +0 -33
- package/dist/lib/browser/intent-resolver-H6OF7V77.mjs.map +0 -7
- package/dist/lib/browser/meta.json +0 -1
- package/dist/lib/browser/react-surface-37LEVBKY.mjs +0 -30
- package/dist/lib/browser/react-surface-37LEVBKY.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-AWLY252W.mjs +0 -60
- package/dist/lib/node-esm/chunk-AWLY252W.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-XZA5WICX.mjs +0 -131
- package/dist/lib/node-esm/chunk-XZA5WICX.mjs.map +0 -7
- package/dist/lib/node-esm/index.mjs +0 -90
- package/dist/lib/node-esm/index.mjs.map +0 -7
- package/dist/lib/node-esm/intent-resolver-L534P6FM.mjs +0 -34
- package/dist/lib/node-esm/intent-resolver-L534P6FM.mjs.map +0 -7
- package/dist/lib/node-esm/meta.json +0 -1
- package/dist/lib/node-esm/react-surface-GVHSH2W2.mjs +0 -31
- package/dist/lib/node-esm/react-surface-GVHSH2W2.mjs.map +0 -7
- package/dist/lib/node-esm/types/index.mjs +0 -8
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/components/BoardContainer.d.ts +0 -8
- package/dist/types/src/components/BoardContainer.d.ts.map +0 -1
- package/dist/types/src/components/BoardContainer.stories.d.ts +0 -45
- package/dist/types/src/components/BoardContainer.stories.d.ts.map +0 -1
- package/src/capabilities/intent-resolver.ts +0 -34
- package/src/components/BoardContainer.stories.tsx +0 -125
- package/src/components/BoardContainer.tsx +0 -136
- /package/dist/lib/{browser/types/index.mjs.map → neutral/chunk-J5LGTIGS.mjs.map} +0 -0
- /package/dist/lib/{node-esm/types → neutral/components}/index.mjs.map +0 -0
package/LICENSE
CHANGED
|
@@ -1,8 +1,105 @@
|
|
|
1
|
-
|
|
2
|
-
Copyright (c) 2022 DXOS
|
|
1
|
+
# Functional Source License, Version 1.1, ALv2 Future License
|
|
3
2
|
|
|
4
|
-
|
|
3
|
+
## Abbreviation
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
FSL-1.1-Apache-2.0
|
|
7
6
|
|
|
8
|
-
|
|
7
|
+
## Notice
|
|
8
|
+
|
|
9
|
+
Copyright 2026 DXOS
|
|
10
|
+
|
|
11
|
+
## Terms and Conditions
|
|
12
|
+
|
|
13
|
+
### Licensor ("We")
|
|
14
|
+
|
|
15
|
+
The party offering the Software under these Terms and Conditions.
|
|
16
|
+
|
|
17
|
+
### The Software
|
|
18
|
+
|
|
19
|
+
The "Software" is each version of the software that we make available under
|
|
20
|
+
these Terms and Conditions, as indicated by our inclusion of these Terms and
|
|
21
|
+
Conditions with the Software.
|
|
22
|
+
|
|
23
|
+
### License Grant
|
|
24
|
+
|
|
25
|
+
Subject to your compliance with this License Grant and the Patents,
|
|
26
|
+
Redistribution and Trademark clauses below, we hereby grant you the right to
|
|
27
|
+
use, copy, modify, create derivative works, publicly perform, publicly display
|
|
28
|
+
and redistribute the Software for any Permitted Purpose identified below.
|
|
29
|
+
|
|
30
|
+
### Permitted Purpose
|
|
31
|
+
|
|
32
|
+
A Permitted Purpose is any purpose other than a Competing Use. A Competing Use
|
|
33
|
+
means making the Software available to others in a commercial product or
|
|
34
|
+
service that:
|
|
35
|
+
|
|
36
|
+
1. substitutes for the Software;
|
|
37
|
+
|
|
38
|
+
2. substitutes for any other product or service we offer using the Software
|
|
39
|
+
that exists as of the date we make the Software available; or
|
|
40
|
+
|
|
41
|
+
3. offers the same or substantially similar functionality as the Software.
|
|
42
|
+
|
|
43
|
+
Permitted Purposes specifically include using the Software:
|
|
44
|
+
|
|
45
|
+
1. for your internal use and access;
|
|
46
|
+
|
|
47
|
+
2. for non-commercial education;
|
|
48
|
+
|
|
49
|
+
3. for non-commercial research; and
|
|
50
|
+
|
|
51
|
+
4. in connection with professional services that you provide to a licensee
|
|
52
|
+
using the Software in accordance with these Terms and Conditions.
|
|
53
|
+
|
|
54
|
+
### Patents
|
|
55
|
+
|
|
56
|
+
To the extent your use for a Permitted Purpose would necessarily infringe our
|
|
57
|
+
patents, the license grant above includes a license under our patents. If you
|
|
58
|
+
make a claim against any party that the Software infringes or contributes to
|
|
59
|
+
the infringement of any patent, then your patent license to the Software ends
|
|
60
|
+
immediately.
|
|
61
|
+
|
|
62
|
+
### Redistribution
|
|
63
|
+
|
|
64
|
+
The Terms and Conditions apply to all copies, modifications and derivatives of
|
|
65
|
+
the Software.
|
|
66
|
+
|
|
67
|
+
If you redistribute any copies, modifications or derivatives of the Software,
|
|
68
|
+
you must include a copy of or a link to these Terms and Conditions and not
|
|
69
|
+
remove any copyright notices provided in or with the Software.
|
|
70
|
+
|
|
71
|
+
### Disclaimer
|
|
72
|
+
|
|
73
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR
|
|
74
|
+
IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR
|
|
75
|
+
PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT.
|
|
76
|
+
|
|
77
|
+
IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE
|
|
78
|
+
SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES,
|
|
79
|
+
EVEN IF WE HAVE BEEN INFORMED OF THEIR POSSIBILITY IN ADVANCE.
|
|
80
|
+
|
|
81
|
+
### Trademarks
|
|
82
|
+
|
|
83
|
+
Except for displaying the License Details and identifying us as the origin of
|
|
84
|
+
the Software, you have no right under these Terms and Conditions to use our
|
|
85
|
+
trademarks, trade names, service marks or product names.
|
|
86
|
+
|
|
87
|
+
## Grant of Future License
|
|
88
|
+
|
|
89
|
+
We hereby irrevocably grant you an additional license to use the Software under
|
|
90
|
+
the Apache License, Version 2.0 that is effective on the second anniversary of
|
|
91
|
+
the date we make the Software available. On or after that date, you may use the
|
|
92
|
+
Software under the Apache License, Version 2.0, in which case the following
|
|
93
|
+
will apply:
|
|
94
|
+
|
|
95
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
96
|
+
this file except in compliance with the License.
|
|
97
|
+
|
|
98
|
+
You may obtain a copy of the License at
|
|
99
|
+
|
|
100
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
101
|
+
|
|
102
|
+
Unless required by applicable law or agreed to in writing, software distributed
|
|
103
|
+
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
|
|
104
|
+
CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
|
105
|
+
specific language governing permissions and limitations under the License.
|
package/PLUGIN.mdl
ADDED
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: org.dxos.plugin.board
|
|
3
|
+
name: BoardPlugin
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
A spatial canvas plugin for `DXOS` Composer that lets users arrange any ECHO objects on an infinite two-dimensional grid.
|
|
8
|
+
Items can be placed freely, moved by dragging, and removed from the canvas without deleting the underlying objects.
|
|
9
|
+
|
|
10
|
+
## Extensions
|
|
11
|
+
|
|
12
|
+
The following extension dialects are used in this document.
|
|
13
|
+
Each extension is defined in the Appendix or resolved via its URI.
|
|
14
|
+
|
|
15
|
+
| Term | URI |
|
|
16
|
+
|-------------|--------------------------------|
|
|
17
|
+
| `type` | `org.dxos.mdl.type@1.0` |
|
|
18
|
+
| `feat` | `org.dxos.mdl.feat@1.0` |
|
|
19
|
+
| `test` | `org.dxos.mdl.test@1.0` |
|
|
20
|
+
| `component` | `org.dxos.mdl.component@1.0` |
|
|
21
|
+
| `op` | `org.dxos.mdl.op@1.0` |
|
|
22
|
+
|
|
23
|
+
## Types
|
|
24
|
+
|
|
25
|
+
```mdl
|
|
26
|
+
type Position
|
|
27
|
+
fields:
|
|
28
|
+
x: number
|
|
29
|
+
y: number
|
|
30
|
+
w?: number
|
|
31
|
+
h?: number
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
```mdl
|
|
35
|
+
type BoardLayout
|
|
36
|
+
fields:
|
|
37
|
+
cells: { [id: string]: Position }
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
```mdl
|
|
41
|
+
type Board
|
|
42
|
+
desc: Root ECHO object (typename org.dxos.type.board).
|
|
43
|
+
fields:
|
|
44
|
+
name?: string
|
|
45
|
+
items: Ref[] # ordered list of references to ECHO objects on the canvas
|
|
46
|
+
layout: BoardLayout # position of every item keyed by object id
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
## Components
|
|
50
|
+
|
|
51
|
+
```mdl
|
|
52
|
+
component BoardArticle
|
|
53
|
+
desc: Full-canvas surface rendered for article and section roles.
|
|
54
|
+
props:
|
|
55
|
+
role: string # AppSurface role (article | section)
|
|
56
|
+
subject: Board # ECHO Board object
|
|
57
|
+
attendableId?: string # attention tracking id
|
|
58
|
+
state:
|
|
59
|
+
items: Obj.Unknown[] # resolved ECHO objects from board.items refs
|
|
60
|
+
pickerState?: PickerState # null when picker closed; Position when open
|
|
61
|
+
slots:
|
|
62
|
+
toolbar?: ReactNode # Board.Toolbar (disabled when not focused)
|
|
63
|
+
cell?: ReactNode # one Surface.Surface per item (Card role)
|
|
64
|
+
actions:
|
|
65
|
+
addItem(anchor, position?) → void
|
|
66
|
+
deleteItem(id: string) → void
|
|
67
|
+
moveItem(id: string, position: Position) → void
|
|
68
|
+
selectFromPicker(id: string) → void
|
|
69
|
+
emits:
|
|
70
|
+
onAdd(anchor: HTMLButtonElement, position?: Position)
|
|
71
|
+
onDelete(id: string)
|
|
72
|
+
onMove(id: string, position: Position)
|
|
73
|
+
layout: |
|
|
74
|
+
┌────────────────────────────────────┐
|
|
75
|
+
│ Board.Toolbar (attention-gated) │
|
|
76
|
+
├────────────────────────────────────┤
|
|
77
|
+
│ Board.Viewport │
|
|
78
|
+
│ ┌──────────────────────────────┐ │
|
|
79
|
+
│ │ Board.Backdrop (+) │ │
|
|
80
|
+
│ │ │ │
|
|
81
|
+
│ │ ┌──────┐ ┌──────┐ │ │
|
|
82
|
+
│ │ │ Cell │ │ Cell │ … │ │
|
|
83
|
+
│ │ └──────┘ └──────┘ │ │
|
|
84
|
+
│ └──────────────────────────────┘ │
|
|
85
|
+
├────────────────────────────────────┤
|
|
86
|
+
│ ObjectPicker (popover, when open) │
|
|
87
|
+
└────────────────────────────────────┘
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Operations
|
|
91
|
+
|
|
92
|
+
```mdl
|
|
93
|
+
op createBoard
|
|
94
|
+
desc: Creates a new Board ECHO object and adds it to the target space.
|
|
95
|
+
input:
|
|
96
|
+
name?: string
|
|
97
|
+
target?: Space
|
|
98
|
+
targetNodeId?: string
|
|
99
|
+
output: Board
|
|
100
|
+
effects: [echo:write]
|
|
101
|
+
note: Delegates to SpaceOperation.AddObject with hidden=true.
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
```mdl
|
|
105
|
+
op addItem
|
|
106
|
+
desc: Adds an ECHO object reference to the board at the given grid position.
|
|
107
|
+
input:
|
|
108
|
+
board: Board
|
|
109
|
+
object: Obj.Unknown
|
|
110
|
+
position: Position
|
|
111
|
+
output: Board
|
|
112
|
+
effects: [echo:write]
|
|
113
|
+
note: |
|
|
114
|
+
When a grid "+" is clicked with a position, a new Markdown document is
|
|
115
|
+
created inline. When the toolbar "+" is clicked without a position, an
|
|
116
|
+
ObjectPicker is shown and the user selects an existing object.
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
```mdl
|
|
120
|
+
op removeItem
|
|
121
|
+
desc: Removes an item reference and its layout entry from the board.
|
|
122
|
+
input:
|
|
123
|
+
board: Board
|
|
124
|
+
id: string
|
|
125
|
+
output: Board
|
|
126
|
+
effects: [echo:write]
|
|
127
|
+
note: Does not delete the underlying ECHO object; only removes it from the canvas.
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
```mdl
|
|
131
|
+
op moveItem
|
|
132
|
+
desc: Updates the grid position for an existing board item.
|
|
133
|
+
input:
|
|
134
|
+
board: Board
|
|
135
|
+
id: string
|
|
136
|
+
position: Position
|
|
137
|
+
output: Board
|
|
138
|
+
effects: [echo:write]
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
## Features
|
|
142
|
+
|
|
143
|
+
```mdl
|
|
144
|
+
feat F-1: Create Board
|
|
145
|
+
|
|
146
|
+
req F-1.1: A new Board is created with an empty items list and an empty layout.
|
|
147
|
+
req F-1.2: The Board is added to the active space using SpaceOperation.AddObject.
|
|
148
|
+
req F-1.3: The Board appears in the space object list immediately after creation.
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
```mdl
|
|
152
|
+
feat F-2: Add Item to Board
|
|
153
|
+
|
|
154
|
+
req F-2.1:
|
|
155
|
+
when: user clicks "+" on the grid backdrop at a specific position
|
|
156
|
+
then: a new Markdown document is created and placed at that position
|
|
157
|
+
|
|
158
|
+
req F-2.2:
|
|
159
|
+
when: user clicks "+" on the toolbar (no position)
|
|
160
|
+
then: ObjectPicker opens, listing all space objects that are not the board itself
|
|
161
|
+
|
|
162
|
+
req F-2.3:
|
|
163
|
+
when: user selects an object from the ObjectPicker
|
|
164
|
+
then: a Ref to that object is appended to board.items; layout entry created at default position
|
|
165
|
+
|
|
166
|
+
req F-2.4: Objects are sorted alphabetically by label in the ObjectPicker.
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
```mdl
|
|
170
|
+
feat F-3: Remove Item from Board
|
|
171
|
+
|
|
172
|
+
req F-3.1:
|
|
173
|
+
when: user deletes a cell
|
|
174
|
+
then: the Ref is removed from board.items and the layout entry is deleted
|
|
175
|
+
note: the referenced ECHO object is not deleted
|
|
176
|
+
|
|
177
|
+
req F-3.2: Board is updated atomically via Obj.update.
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
```mdl
|
|
181
|
+
feat F-4: Move Item on Board
|
|
182
|
+
|
|
183
|
+
req F-4.1:
|
|
184
|
+
when: user drags a card to a new position
|
|
185
|
+
then: board.layout.cells[id] is updated with the new Position
|
|
186
|
+
|
|
187
|
+
req F-4.2: Other items are not affected by a move operation.
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
```mdl
|
|
191
|
+
feat F-5: Render Items
|
|
192
|
+
|
|
193
|
+
req F-5.1: Each item in board.items is rendered as a Surface.Surface with the Card role.
|
|
194
|
+
req F-5.2:
|
|
195
|
+
when: an item's Ref cannot be resolved (deleted object)
|
|
196
|
+
then: the cell is silently omitted from the rendered canvas
|
|
197
|
+
|
|
198
|
+
req F-5.3: Items are rendered in board.items order; z-ordering follows index.
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
```mdl
|
|
202
|
+
feat F-6: Attention and Focus
|
|
203
|
+
|
|
204
|
+
req F-6.1:
|
|
205
|
+
when: the Board surface does not have attention
|
|
206
|
+
then: Board.Toolbar is rendered in disabled state; drag and add interactions are suppressed
|
|
207
|
+
|
|
208
|
+
req F-6.2:
|
|
209
|
+
when: the Board surface gains attention
|
|
210
|
+
then: Board.Toolbar becomes interactive
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
## Acceptance
|
|
214
|
+
|
|
215
|
+
```mdl
|
|
216
|
+
test T-1: New board is empty
|
|
217
|
+
given: a new Board has been created
|
|
218
|
+
then:
|
|
219
|
+
- board.items is empty
|
|
220
|
+
- board.layout.cells is empty
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
```mdl
|
|
224
|
+
test T-2: Add item via grid backdrop
|
|
225
|
+
given: an empty board is displayed
|
|
226
|
+
when: user clicks the "+" hotspot at position (100, 200)
|
|
227
|
+
then:
|
|
228
|
+
- a Markdown document is created in the space
|
|
229
|
+
- board.items contains a Ref to the new document
|
|
230
|
+
- board.layout.cells[doc.id] === { x: 100, y: 200 }
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
```mdl
|
|
234
|
+
test T-3: Add existing object via picker
|
|
235
|
+
given: the space contains a Document with label "Meeting notes"
|
|
236
|
+
when: user opens the ObjectPicker from the toolbar and selects "Meeting notes"
|
|
237
|
+
then:
|
|
238
|
+
- board.items contains a Ref to the Document
|
|
239
|
+
- board.layout.cells[doc.id] === { x: 0, y: 0 }
|
|
240
|
+
- picker is closed
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
```mdl
|
|
244
|
+
test T-4: Remove item
|
|
245
|
+
given: board has one item
|
|
246
|
+
when: user deletes the cell
|
|
247
|
+
then:
|
|
248
|
+
- board.items is empty
|
|
249
|
+
- board.layout.cells is empty
|
|
250
|
+
- the referenced ECHO object still exists in the space
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
```mdl
|
|
254
|
+
test T-5: Move item
|
|
255
|
+
given: board has one item at position { x: 0, y: 0 }
|
|
256
|
+
when: user drags it to { x: 300, y: 150 }
|
|
257
|
+
then:
|
|
258
|
+
- board.layout.cells[item.id] === { x: 300, y: 150 }
|
|
259
|
+
- board.items length is unchanged
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
```mdl
|
|
263
|
+
test T-6: Toolbar gated by attention
|
|
264
|
+
given: board is rendered without focus
|
|
265
|
+
then: Board.Toolbar is disabled
|
|
266
|
+
when: board gains focus
|
|
267
|
+
then: Board.Toolbar is interactive
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
---
|
|
271
|
+
|
|
272
|
+
## Appendix: Extension Definitions
|
|
273
|
+
|
|
274
|
+
Extension block types used in this document are defined below using
|
|
275
|
+
the core `ext` primitive — the only construct the base language provides.
|
|
276
|
+
|
|
277
|
+
```mdl
|
|
278
|
+
ext type
|
|
279
|
+
uri: org.dxos.mdl.type@1.0
|
|
280
|
+
desc: A named data structure with typed fields and optional literals.
|
|
281
|
+
fields:
|
|
282
|
+
desc?: Prose
|
|
283
|
+
fields?: FieldMap # name[?]: TypeExpr (# inline comment)
|
|
284
|
+
literals?: UnionList # a | b | c
|
|
285
|
+
extends?: TypeRef[]
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
```mdl
|
|
289
|
+
ext feat
|
|
290
|
+
uri: org.dxos.mdl.feat@1.0
|
|
291
|
+
desc: A named feature grouping one or more requirements.
|
|
292
|
+
fields:
|
|
293
|
+
desc?: Prose
|
|
294
|
+
req: RequirementList
|
|
295
|
+
nesting: self # feat blocks may contain feat blocks
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
```mdl
|
|
299
|
+
ext test
|
|
300
|
+
uri: org.dxos.mdl.test@1.0
|
|
301
|
+
desc: An acceptance scenario expressed as given / when / then steps.
|
|
302
|
+
fields:
|
|
303
|
+
given?: Step | Step[]
|
|
304
|
+
when?: Step | Step[]
|
|
305
|
+
then: Step | Step[]
|
|
306
|
+
tags?: TagList
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
```mdl
|
|
310
|
+
ext component
|
|
311
|
+
uri: org.dxos.mdl.component@1.0
|
|
312
|
+
desc: A UI component with props, internal state, slots, actions, and events.
|
|
313
|
+
fields:
|
|
314
|
+
desc?: Prose
|
|
315
|
+
props?: FieldMap # external inputs (immutable inside component)
|
|
316
|
+
state?: FieldMap # internal reactive state
|
|
317
|
+
slots?: FieldMap # named ReactNode injection points
|
|
318
|
+
actions?: ActionMap # methods the component exposes or handles
|
|
319
|
+
emits?: EventMap # events the component raises to its parent
|
|
320
|
+
layout?: CodeBlock # ASCII sketch of visual structure (non-normative)
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
```mdl
|
|
324
|
+
ext op
|
|
325
|
+
uri: org.dxos.mdl.op@1.0
|
|
326
|
+
desc: |
|
|
327
|
+
A named operation with typed inputs, outputs, and declared errors.
|
|
328
|
+
Pure ops have no effects or requires. Effectful ops declare both.
|
|
329
|
+
fields:
|
|
330
|
+
desc?: Prose
|
|
331
|
+
input?: FieldMap # named input parameters
|
|
332
|
+
output?: TypeExpr # return type
|
|
333
|
+
errors?: ErrorMap # name: Prose (when this error occurs)
|
|
334
|
+
effects?: EffectList # echo:read | echo:write | http | fs | ...
|
|
335
|
+
requires?: ServiceList # injected service dependencies
|
|
336
|
+
note?: Prose # implementation guidance (non-normative)
|
|
337
|
+
```
|
package/README.md
CHANGED
|
@@ -12,4 +12,4 @@ Surface plugin for card baords.
|
|
|
12
12
|
|
|
13
13
|
Your ideas, issues, and code are most welcome. Please take a look at our [community code of conduct](https://github.com/dxos/dxos/blob/main/CODE_OF_CONDUCT.md), the [issue guide](https://github.com/dxos/dxos/blob/main/CONTRIBUTING.md#submitting-issues), and the [PR contribution guide](https://github.com/dxos/dxos/blob/main/CONTRIBUTING.md#submitting-prs).
|
|
14
14
|
|
|
15
|
-
License: [
|
|
15
|
+
License: [FSL-1.1-Apache-2.0](./LICENSE) Copyright 2023 © DXOS
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
import "./chunk-J5LGTIGS.mjs";
|
|
2
|
+
|
|
3
|
+
// src/containers/BoardArticle/BoardArticle.tsx
|
|
4
|
+
import { useAtomValue } from "@effect-atom/atom-react";
|
|
5
|
+
import * as Atom from "@effect-atom/atom/Atom";
|
|
6
|
+
import React, { useCallback, useMemo, useRef, useState } from "react";
|
|
7
|
+
import { Surface } from "@dxos/app-framework/ui";
|
|
8
|
+
import { AppSurface } from "@dxos/app-toolkit/ui";
|
|
9
|
+
import { Filter, Obj, Ref } from "@dxos/echo";
|
|
10
|
+
import { AtomObj } from "@dxos/echo-atom";
|
|
11
|
+
import { useObject } from "@dxos/echo-react";
|
|
12
|
+
import { invariant } from "@dxos/invariant";
|
|
13
|
+
import { EID } from "@dxos/keys";
|
|
14
|
+
import { Markdown } from "@dxos/plugin-markdown";
|
|
15
|
+
import { useQuery } from "@dxos/react-client/echo";
|
|
16
|
+
import { Panel } from "@dxos/react-ui";
|
|
17
|
+
import { useAttention } from "@dxos/react-ui-attention";
|
|
18
|
+
import { Board } from "@dxos/react-ui-board";
|
|
19
|
+
import { ObjectPicker } from "@dxos/react-ui-form";
|
|
20
|
+
import { isNonNullable } from "@dxos/util";
|
|
21
|
+
var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-board/src/containers/BoardArticle/BoardArticle.tsx";
|
|
22
|
+
var DEFAULT_POSITION = {
|
|
23
|
+
x: 0,
|
|
24
|
+
y: 0
|
|
25
|
+
};
|
|
26
|
+
var BoardArticle = ({ role, subject: board, attendableId }) => {
|
|
27
|
+
const { hasAttention } = useAttention(attendableId);
|
|
28
|
+
const db = Obj.getDatabase(board);
|
|
29
|
+
const [boardItems] = useObject(board, "items");
|
|
30
|
+
const itemsAtom = useMemo(() => Atom.make((get) => {
|
|
31
|
+
const result = [];
|
|
32
|
+
for (const ref of boardItems ?? []) {
|
|
33
|
+
const obj = get(AtomObj.makeWithReactive(ref));
|
|
34
|
+
if (obj) {
|
|
35
|
+
result.push(obj);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return result;
|
|
39
|
+
}), [
|
|
40
|
+
boardItems
|
|
41
|
+
]);
|
|
42
|
+
const items = useAtomValue(itemsAtom);
|
|
43
|
+
const controller = useRef(null);
|
|
44
|
+
const addTriggerRef = useRef(null);
|
|
45
|
+
const [pickerState, setPickerState] = useState(null);
|
|
46
|
+
const objects = useQuery(db, Filter.everything());
|
|
47
|
+
const options = useMemo(() => objects.filter((obj) => obj.id !== board.id).map((obj) => {
|
|
48
|
+
const label = Obj.getLabel(obj);
|
|
49
|
+
if (label) {
|
|
50
|
+
return {
|
|
51
|
+
id: obj.id,
|
|
52
|
+
label,
|
|
53
|
+
hue: "neutral"
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
}).filter(isNonNullable).sort(({ label: a }, { label: b }) => a.toLocaleLowerCase().localeCompare(b.toLocaleLowerCase())), [
|
|
57
|
+
objects
|
|
58
|
+
]);
|
|
59
|
+
const handleAdd = useCallback(async (anchor, position) => {
|
|
60
|
+
const db2 = Obj.getDatabase(board);
|
|
61
|
+
invariant(db2, void 0, { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 61, S: void 0, A: ["db", ""] });
|
|
62
|
+
if (position) {
|
|
63
|
+
const doc = db2.add(Markdown.make());
|
|
64
|
+
Obj.update(board, (board2) => {
|
|
65
|
+
board2.items.push(Ref.make(doc));
|
|
66
|
+
board2.layout.cells[doc.id.toString()] = position;
|
|
67
|
+
});
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
addTriggerRef.current = anchor;
|
|
71
|
+
setPickerState({
|
|
72
|
+
position: DEFAULT_POSITION
|
|
73
|
+
});
|
|
74
|
+
}, [
|
|
75
|
+
board
|
|
76
|
+
]);
|
|
77
|
+
const handleDelete = useCallback((id) => {
|
|
78
|
+
const idx = board.items.findIndex((ref) => {
|
|
79
|
+
const echoUri = EID.tryParse(ref.uri);
|
|
80
|
+
return (echoUri ? EID.getEntityId(echoUri) : void 0) === id;
|
|
81
|
+
});
|
|
82
|
+
Obj.update(board, (board2) => {
|
|
83
|
+
if (idx !== -1) {
|
|
84
|
+
board2.items.splice(idx, 1);
|
|
85
|
+
}
|
|
86
|
+
delete board2.layout.cells[id];
|
|
87
|
+
});
|
|
88
|
+
}, [
|
|
89
|
+
board
|
|
90
|
+
]);
|
|
91
|
+
const handleMove = useCallback((id, position) => {
|
|
92
|
+
const layout = board.layout.cells[id];
|
|
93
|
+
Obj.update(board, (board2) => {
|
|
94
|
+
board2.layout.cells[id] = {
|
|
95
|
+
...layout,
|
|
96
|
+
...position
|
|
97
|
+
};
|
|
98
|
+
});
|
|
99
|
+
}, [
|
|
100
|
+
board
|
|
101
|
+
]);
|
|
102
|
+
const handleSelect = useCallback((id) => {
|
|
103
|
+
if (!pickerState) {
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
const selectedObject = objects.find((obj) => obj.id === id);
|
|
107
|
+
if (!Obj.isObject(selectedObject)) {
|
|
108
|
+
return;
|
|
109
|
+
}
|
|
110
|
+
Obj.update(board, (board2) => {
|
|
111
|
+
board2.items.push(Ref.make(selectedObject));
|
|
112
|
+
board2.layout.cells[selectedObject.id.toString()] = pickerState.position;
|
|
113
|
+
});
|
|
114
|
+
setPickerState(null);
|
|
115
|
+
}, [
|
|
116
|
+
pickerState,
|
|
117
|
+
objects,
|
|
118
|
+
board
|
|
119
|
+
]);
|
|
120
|
+
return /* @__PURE__ */ React.createElement(Board.Root, {
|
|
121
|
+
ref: controller,
|
|
122
|
+
layout: board.layout,
|
|
123
|
+
onAdd: handleAdd,
|
|
124
|
+
onDelete: handleDelete,
|
|
125
|
+
onMove: handleMove
|
|
126
|
+
}, /* @__PURE__ */ React.createElement(ObjectPicker.Root, {
|
|
127
|
+
open: !!pickerState,
|
|
128
|
+
onOpenChange: (nextOpen) => {
|
|
129
|
+
setPickerState(nextOpen ? {
|
|
130
|
+
position: DEFAULT_POSITION
|
|
131
|
+
} : null);
|
|
132
|
+
}
|
|
133
|
+
}, /* @__PURE__ */ React.createElement(Panel.Root, {
|
|
134
|
+
role
|
|
135
|
+
}, /* @__PURE__ */ React.createElement(Panel.Toolbar, {
|
|
136
|
+
asChild: true
|
|
137
|
+
}, /* @__PURE__ */ React.createElement(Board.Toolbar, {
|
|
138
|
+
disabled: !hasAttention
|
|
139
|
+
})), /* @__PURE__ */ React.createElement(Panel.Content, {
|
|
140
|
+
asChild: true
|
|
141
|
+
}, /* @__PURE__ */ React.createElement(Board.Container, null, /* @__PURE__ */ React.createElement(Board.Viewport, {
|
|
142
|
+
classNames: "border-none"
|
|
143
|
+
}, /* @__PURE__ */ React.createElement(Board.Backdrop, null), /* @__PURE__ */ React.createElement(Board.Content, null, items?.map((item, index) => /* @__PURE__ */ React.createElement(Board.Cell, {
|
|
144
|
+
item,
|
|
145
|
+
key: index,
|
|
146
|
+
layout: board.layout?.cells[item.id] ?? {
|
|
147
|
+
x: 0,
|
|
148
|
+
y: 0
|
|
149
|
+
}
|
|
150
|
+
}, /* @__PURE__ */ React.createElement(Surface.Surface, {
|
|
151
|
+
type: AppSurface.Card,
|
|
152
|
+
data: {
|
|
153
|
+
subject: item,
|
|
154
|
+
editable: true
|
|
155
|
+
},
|
|
156
|
+
limit: 1
|
|
157
|
+
})))))))), /* @__PURE__ */ React.createElement(ObjectPicker.Content, {
|
|
158
|
+
options,
|
|
159
|
+
onSelect: handleSelect,
|
|
160
|
+
classNames: "dx-card-popover-width"
|
|
161
|
+
}), /* @__PURE__ */ React.createElement(ObjectPicker.VirtualTrigger, {
|
|
162
|
+
virtualRef: addTriggerRef
|
|
163
|
+
})));
|
|
164
|
+
};
|
|
165
|
+
export {
|
|
166
|
+
BoardArticle as default
|
|
167
|
+
};
|
|
168
|
+
//# sourceMappingURL=BoardArticle-XCMTXRNW.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/containers/BoardArticle/BoardArticle.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { useAtomValue } from '@effect-atom/atom-react';\nimport * as Atom from '@effect-atom/atom/Atom';\nimport React, { useCallback, useMemo, useRef, useState } from 'react';\n\nimport { Surface } from '@dxos/app-framework/ui';\nimport { AppSurface } from '@dxos/app-toolkit/ui';\nimport { Filter, Obj, Ref } from '@dxos/echo';\nimport { AtomObj } from '@dxos/echo-atom';\nimport { useObject } from '@dxos/echo-react';\nimport { invariant } from '@dxos/invariant';\nimport { EID } from '@dxos/keys';\nimport { Markdown } from '@dxos/plugin-markdown';\nimport { useQuery } from '@dxos/react-client/echo';\nimport { Panel } from '@dxos/react-ui';\nimport { useAttention } from '@dxos/react-ui-attention';\nimport { Board, type BoardController, type BoardRootProps, type Position } from '@dxos/react-ui-board';\nimport { ObjectPicker, type ObjectPickerContentProps } from '@dxos/react-ui-form';\nimport { isNonNullable } from '@dxos/util';\n\nimport { type Board as BoardType } from '#types';\n\nconst DEFAULT_POSITION = { x: 0, y: 0 } satisfies Position;\n\ntype PickerState = {\n position: Position;\n};\n\nexport type BoardArticleProps = AppSurface.ObjectArticleProps<BoardType.Board>;\n\nexport const BoardArticle = ({ role, subject: board, attendableId }: BoardArticleProps) => {\n const { hasAttention } = useAttention(attendableId);\n const db = Obj.getDatabase(board);\n const [boardItems] = useObject(board, 'items');\n const itemsAtom = useMemo(\n () =>\n Atom.make((get) => {\n const result: Obj.Unknown[] = [];\n for (const ref of boardItems ?? []) {\n const obj = get(AtomObj.makeWithReactive(ref));\n if (obj) {\n result.push(obj);\n }\n }\n return result;\n }),\n [boardItems],\n );\n const items = useAtomValue(itemsAtom);\n\n const controller = useRef<BoardController>(null);\n const addTriggerRef = useRef<HTMLButtonElement | null>(null);\n const [pickerState, setPickerState] = useState<PickerState | null>(null);\n\n // TODO(burdon): Use search.\n const objects = useQuery(db, Filter.everything());\n const options = useMemo<ObjectPickerContentProps['options']>(\n () =>\n objects\n .filter((obj) => obj.id !== board.id)\n .map((obj) => {\n const label = Obj.getLabel(obj);\n if (label) {\n return {\n id: obj.id,\n label,\n hue: 'neutral' as const,\n };\n }\n })\n .filter(isNonNullable)\n .sort(({ label: a }, { label: b }) => a.toLocaleLowerCase().localeCompare(b.toLocaleLowerCase())),\n [objects],\n );\n\n const handleAdd = useCallback<NonNullable<BoardRootProps['onAdd']>>(\n async (anchor, position) => {\n const db = Obj.getDatabase(board);\n invariant(db);\n // Grid backdrop \"+\" supplies a position → create a new Markdown document directly.\n // Toolbar \"+\" omits position → fall back to the picker over existing objects.\n if (position) {\n const doc = db.add(Markdown.make());\n Obj.update(board, (board) => {\n board.items.push(Ref.make(doc));\n board.layout.cells[doc.id.toString()] = position;\n });\n return;\n }\n\n addTriggerRef.current = anchor;\n setPickerState({ position: DEFAULT_POSITION });\n },\n [board],\n );\n\n // TODO(burdon): Use intents so can be undone.\n const handleDelete = useCallback<NonNullable<BoardRootProps['onDelete']>>(\n (id) => {\n // TODO(burdon): Impl. DXN.equals and pass in DXN from `id`.\n const idx = board.items.findIndex((ref) => {\n const echoUri = EID.tryParse(ref.uri);\n return (echoUri ? EID.getEntityId(echoUri) : undefined) === id;\n });\n Obj.update(board, (board) => {\n if (idx !== -1) {\n board.items.splice(idx, 1);\n }\n delete board.layout.cells[id];\n });\n },\n [board],\n );\n\n const handleMove = useCallback<NonNullable<BoardRootProps['onMove']>>(\n (id, position) => {\n const layout = board.layout.cells[id];\n Obj.update(board, (board) => {\n board.layout.cells[id] = { ...layout, ...position };\n });\n },\n [board],\n );\n\n const handleSelect = useCallback<NonNullable<ObjectPickerContentProps['onSelect']>>(\n (id) => {\n if (!pickerState) {\n return;\n }\n\n // Find the selected object by id from the space.\n const selectedObject = objects.find((obj) => obj.id === id);\n if (!Obj.isObject(selectedObject)) {\n return;\n }\n\n // Create a reference to the selected object and add it to the board.\n Obj.update(board, (board) => {\n board.items.push(Ref.make(selectedObject));\n\n // Set the layout position for the new item.\n board.layout.cells[selectedObject.id.toString()] = pickerState.position;\n });\n\n // Close the picker.\n setPickerState(null);\n },\n [pickerState, objects, board],\n );\n\n return (\n <Board.Root ref={controller} layout={board.layout} onAdd={handleAdd} onDelete={handleDelete} onMove={handleMove}>\n <ObjectPicker.Root\n open={!!pickerState}\n onOpenChange={(nextOpen: boolean) => {\n setPickerState(nextOpen ? { position: DEFAULT_POSITION } : null);\n }}\n >\n <Panel.Root role={role}>\n <Panel.Toolbar asChild>\n <Board.Toolbar disabled={!hasAttention} />\n </Panel.Toolbar>\n <Panel.Content asChild>\n <Board.Container>\n <Board.Viewport classNames='border-none'>\n <Board.Backdrop />\n <Board.Content>\n {items?.map((item, index) => (\n <Board.Cell item={item} key={index} layout={board.layout?.cells[item.id] ?? { x: 0, y: 0 }}>\n <Surface.Surface type={AppSurface.Card} data={{ subject: item, editable: true }} limit={1} />\n </Board.Cell>\n ))}\n </Board.Content>\n </Board.Viewport>\n </Board.Container>\n </Panel.Content>\n </Panel.Root>\n <ObjectPicker.Content options={options} onSelect={handleSelect} classNames='dx-card-popover-width' />\n <ObjectPicker.VirtualTrigger virtualRef={addTriggerRef} />\n </ObjectPicker.Root>\n </Board.Root>\n );\n};\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": ["useAtomValue", "Atom", "React", "useCallback", "useMemo", "useRef", "useState", "Surface", "AppSurface", "Filter", "Obj", "Ref", "AtomObj", "useObject", "invariant", "EID", "Markdown", "useQuery", "Panel", "useAttention", "Board", "ObjectPicker", "isNonNullable", "DEFAULT_POSITION", "y", "db", "getDatabase", "board", "boardItems", "itemsAtom", "result", "obj", "get", "push", "addTriggerRef", "pickerState", "setPickerState", "objects", "everything", "label", "getLabel", "id", "hue", "filter", "items", "make", "doc", "layout", "cells", "findIndex", "ref", "echoUri", "getEntityId", "update", "idx", "position", "selectedObject", "toString", "onAdd", "onDelete", "handleDelete", "onMove", "open", "onOpenChange", "nextOpen", "role", "Toolbar", "asChild", "disabled", "Container", "classNames", "Backdrop", "Content", "item", "index", "x", "type", "subject", "editable", "limit", "options", "onSelect", "handleSelect", "virtualRef"]
|
|
7
|
+
}
|