Skip to content

Commit cd34b22

Browse files
authored
Update sdk (#265)
Signed-off-by: lornakelly <lornakelly88@gmail.com>
1 parent 91d2e7b commit cd34b22

30 files changed

Lines changed: 55 additions & 50 deletions

.changeset/update-sdk.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@openworkflowspec/diagram-editor": minor
3+
---
4+
5+
Update sdk package to new openworkflowspec package

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ This project uses the following technology stack:
5555
- **Language**: [TypeScript](https://www.typescriptlang.org/) with strict mode enabled
5656
- **UI Library**: [React](https://react.dev/)
5757
- **Diagram Rendering**: [@xyflow/react](https://reactflow.dev/) (isolated in `src/react-flow/`)
58-
- **Workflow SDK**: [@serverlessworkflow/sdk](https://github.com/serverlessworkflow/sdk-typescript) (isolated in `src/core/`)
58+
- **Workflow SDK**: [@openworkflowspec/sdk](https://github.com/open-workflow-specification/sdk-typescript) (isolated in `src/core/`)
5959
- **Testing**: [Vitest](https://vitest.dev/) for unit tests, [Playwright](https://playwright.dev/) for E2E
6060
- **Linting**: [oxlint](https://oxc.rs/) with TypeScript, React, import, and jsx-a11y plugins
6161
- **Formatting**: [oxfmt](https://oxc.rs/)

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ The main visual diagram editor component built with:
139139
- **TypeScript** (strict mode)
140140
- **React**
141141
- **[@xyflow/react](https://reactflow.dev/)** for diagram rendering (isolated in `src/react-flow/`)
142-
- **[@serverlessworkflow/sdk](https://github.com/serverlessworkflow/sdk-typescript)** (isolated in `src/core/`)
142+
- **[@openworkflowspec/sdk](https://github.com/open-workflow-specification/sdk-typescript)** (isolated in `src/core/`)
143143
- **[shadcn/ui](https://ui.shadcn.com/)** for UI primitives (with `dec:` Tailwind prefix)
144144
- **[Storybook](https://storybook.js.org/)** for component development
145145
- **[Vitest](https://vitest.dev/)** and **[Playwright](https://playwright.dev/)** for testing
@@ -154,7 +154,7 @@ Internationalization utilities used by the diagram editor.
154154
- **UI Framework**: [React](https://react.dev/)
155155
- **Diagram Library**: [@xyflow/react](https://reactflow.dev/) (React Flow)
156156
- **Auto Layout**: [ELK.js](https://eclipse.dev/elk/)
157-
- **Workflow SDK**: [@serverlessworkflow/sdk](https://github.com/serverlessworkflow/sdk-typescript)
157+
- **Workflow SDK**: [@openworkflowspec/sdk](https://github.com/open-workflow-specification/sdk-typescript)
158158
- **UI Components**: [shadcn/ui](https://ui.shadcn.com/) + [Radix UI](https://www.radix-ui.com/)
159159
- **Styling**: [Tailwind CSS](https://tailwindcss.com/)
160160
- **Testing**: [Vitest](https://vitest.dev/), [Playwright](https://playwright.dev/)
@@ -232,4 +232,4 @@ This project is licensed under the [Apache License 2.0](LICENSE).
232232
## Related Projects
233233

234234
- [Open Workflow Specification](https://github.com/open-workflow-specification/specification)
235-
- [Open Workflow SDK (TypeScript)](https://github.com/serverlessworkflow/sdk-typescript)
235+
- [Open Workflow SDK (TypeScript)](https://github.com/open-workflow-specification/sdk-typescript)

packages/open-workflow-diagram-editor/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
},
4343
"dependencies": {
4444
"@openworkflowspec/i18n": "workspace:*",
45-
"@serverlessworkflow/sdk": "catalog:",
45+
"@openworkflowspec/sdk": "catalog:",
4646
"@xyflow/react": "catalog:",
4747
"class-variance-authority": "catalog:",
4848
"clsx": "catalog:",

packages/open-workflow-diagram-editor/src/core/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ The core layer serves as the abstraction boundary between the Open Workflow SDK
2626

2727
### SDK Abstraction
2828

29-
**Critical constraint**: This is the only layer allowed to directly import from `@serverlessworkflow/sdk`. All SDK interactions must go through this abstraction to keep the rest of the editor decoupled from SDK implementation details. Despite of that, type-only imports may still be used elsewhere when needed.
29+
**Critical constraint**: This is the only layer allowed to directly import from `@openworkflowspec/sdk`. All SDK interactions must go through this abstraction to keep the rest of the editor decoupled from SDK implementation details. Despite of that, type-only imports may still be used elsewhere when needed.
3030

3131
Responsibilities:
3232

packages/open-workflow-diagram-editor/src/core/graph.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
import { FlatGraph, FlatGraphNode, GraphNodeType } from "@serverlessworkflow/sdk";
17+
import { FlatGraph, FlatGraphNode, GraphNodeType } from "@openworkflowspec/sdk";
1818

1919
export function getNodesByType(graph: FlatGraph, type: GraphNodeType): FlatGraphNode[] {
2020
return graph.nodes.filter((node) => node.type === type);

packages/open-workflow-diagram-editor/src/core/mermaidExport.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
* limitations under the License.
1515
*/
1616

17-
import { convertToMermaidCode } from "@serverlessworkflow/sdk";
18-
import type { Specification } from "@serverlessworkflow/sdk";
17+
import { convertToMermaidCode } from "@openworkflowspec/sdk";
18+
import type { Specification } from "@openworkflowspec/sdk";
1919

2020
/**
2121
* Converts a workflow model to Mermaid diagram code

packages/open-workflow-diagram-editor/src/core/taskDetails.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
import type { Specification } from "@serverlessworkflow/sdk";
17+
import type { Specification } from "@openworkflowspec/sdk";
1818

1919
/* TaskBase: Common fields every task inherits (none required) (metadata is dropped for now) */
2020
const TASK_BASE_KEYS = new Set(["if", "input", "output", "export", "timeout", "then", "metadata"]);

packages/open-workflow-diagram-editor/src/core/taskSubType.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
import type { Specification } from "@serverlessworkflow/sdk";
17+
import type { Specification } from "@openworkflowspec/sdk";
1818

1919
function getFirstKey(obj: unknown): string | undefined {
2020
return obj && typeof obj === "object" && !Array.isArray(obj) ? Object.keys(obj)[0] : undefined;

packages/open-workflow-diagram-editor/src/core/workflowSdk.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616

1717
import { load } from "js-yaml";
18-
import * as sdk from "@serverlessworkflow/sdk";
18+
import * as sdk from "@openworkflowspec/sdk";
1919
import { fixNodesConnections } from "./graph";
2020

2121
/**

0 commit comments

Comments
 (0)