-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrating to use @deco/deco from jsr (#845)
* Migrating to use @deco/deco from jsr Signed-off-by: Marcos Candeia <[email protected]> * Add necessary imports Signed-off-by: Marcos Candeia <[email protected]> * Use setcookie from std Signed-off-by: Marcos Candeia <[email protected]> * Upgrade deco version Signed-off-by: Marcos Candeia <[email protected]> --------- Signed-off-by: Marcos Candeia <[email protected]>
- Loading branch information
Showing
168 changed files
with
1,147 additions
and
2,845 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,41 @@ | ||
import { type Resolvable } from "deco/engine/core/resolver.ts"; | ||
import { type fjp } from "./deps.ts"; | ||
|
||
import { type Resolvable } from "@deco/deco"; | ||
export interface Pagination<T> { | ||
data: T[]; | ||
page: number; | ||
pageSize: number; | ||
total: number; | ||
} | ||
|
||
export interface PatchState { | ||
type: "patch-state"; | ||
payload: fjp.Operation[]; | ||
revision: string; | ||
} | ||
|
||
export interface FetchState { | ||
type: "fetch-state"; | ||
} | ||
|
||
export interface StatePatched { | ||
type: "state-patched"; | ||
payload: fjp.Operation[]; | ||
revision: string; | ||
// Maybe add data and user info in here | ||
metadata?: unknown; | ||
} | ||
|
||
export interface StateFetched { | ||
type: "state-fetched"; | ||
payload: State; | ||
} | ||
|
||
export interface OperationFailed { | ||
type: "operation-failed"; | ||
code: "UNAUTHORIZED" | "INTERNAL_SERVER_ERROR"; | ||
reason: string; | ||
} | ||
|
||
export type Acked<T> = T & { ack: string }; | ||
|
||
export type Acked<T> = T & { | ||
ack: string; | ||
}; | ||
export interface State { | ||
decofile: Record<string, Resolvable>; | ||
revision: string; | ||
} | ||
|
||
export type Commands = PatchState | FetchState; | ||
export type Events = StatePatched | StateFetched | OperationFailed; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.