sg-widgets-core 0.1.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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Kevin Sallee and contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,25 @@
1
+ # sg-widgets-core
2
+
3
+ A headless model of Flow Production Tracking (ShotGrid) fields, filters, statuses and rows. No
4
+ framework, no dependencies. The React and Svelte widgets of sg-widgets are built on it, and an app
5
+ that draws its own components uses it on its own.
6
+
7
+ ```sh
8
+ npm install sg-widgets-core
9
+ ```
10
+
11
+ What it holds:
12
+
13
+ | group | what |
14
+ |---|---|
15
+ | client | One interface over the REST API with a token, over an app's own endpoints with a matching server handler, and over a generated site for tests, which lives on the `sg-widgets-core/mock` subpath. A cache decorates any of them, and a context carries the client, the schema and status services and the site preferences. |
16
+ | schema | Field data types, what each accepts, display names, and the schema service that reads a type once and answers from memory. |
17
+ | filter | The filter tree, the operators each data type offers, the serialisation the API takes, and the facets a filter bar counts. |
18
+ | render | One line of text for a value of any data type: durations, timecodes, floats, currencies, dates, statuses and entity names. |
19
+ | edit | The parse behind every editor: what a person may type for a data type, what comes back as the stored value, and what is refused. |
20
+
21
+ What the package claims about the API comes from a recorded corpus of what a site answers, cited in
22
+ the code where it is encoded.
23
+
24
+ Documentation, the props of every widget and live demos of both frameworks:
25
+ <https://sg-widgets.vercel.app>