@effect-app/vue 2.84.5 → 2.86.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/CHANGELOG.md +12 -0
- package/dist/experimental/commander.d.ts +79 -72
- package/dist/experimental/commander.d.ts.map +1 -1
- package/dist/experimental/commander.js +26 -8
- package/dist/experimental/withToast.d.ts +1 -0
- package/dist/experimental/withToast.d.ts.map +1 -1
- package/dist/experimental/withToast.js +5 -2
- package/dist/makeClient.d.ts +8 -8
- package/package.json +1 -1
- package/src/experimental/commander.ts +371 -319
- package/src/experimental/withToast.ts +8 -2
- package/test/Mutation.test.ts +24 -15
- package/test/dist/stubs.d.ts +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @effect-app/vue
|
|
2
2
|
|
|
3
|
+
## 2.86.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 371b1ba: Change Commander to be unary and pass Context as second arg.
|
|
8
|
+
|
|
9
|
+
## 2.85.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- 519ca08: feat: add stable toast id support
|
|
14
|
+
|
|
3
15
|
## 2.84.5
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
@@ -89,11 +89,11 @@ export type EmitWithCallback<A, Event extends string> = (event: Event, value: A,
|
|
|
89
89
|
*/
|
|
90
90
|
export declare const wrapEmit: <A, Event extends string>(emit: EmitWithCallback<A, NoInfer<Event>>, event: Event) => (value: A) => Promise<void>;
|
|
91
91
|
export declare namespace Commander {
|
|
92
|
-
type CommanderBase<RT, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> =
|
|
92
|
+
type CommanderBase<RT, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> = Gen<RT, Id, I18nKey, State> & NonGen<RT, Id, I18nKey, State> & CommandContextLocal<Id, I18nKey> & {
|
|
93
93
|
state: Context.Tag<`Commander.Command.${Id}.state`, State>;
|
|
94
94
|
};
|
|
95
95
|
type CommanderFn<RT, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> = CommanderBase<RT, Id, I18nKey, State>;
|
|
96
|
-
type CommanderWrap<RT, Id extends string, I18nCustomKey extends string, State extends IntlRecord | undefined, I
|
|
96
|
+
type CommanderWrap<RT, Id extends string, I18nCustomKey extends string, State extends IntlRecord | undefined, I, A, E, R> = CommandContextLocal<Id, I18nCustomKey> & GenWrap<RT, Id, I18nCustomKey, I, A, E, R, State> & NonGenWrap<RT, Id, I18nCustomKey, I, A, E, R, State> & {
|
|
97
97
|
state: Context.Tag<`Commander.Command.${Id}.state`, State>;
|
|
98
98
|
};
|
|
99
99
|
interface CommandContextLocal<Id extends string, I18nKey extends string> {
|
|
@@ -114,102 +114,105 @@ export declare namespace Commander {
|
|
|
114
114
|
/** reactive */
|
|
115
115
|
state: ComputedRef<State>;
|
|
116
116
|
}
|
|
117
|
-
interface CommandOut<
|
|
117
|
+
interface CommandOut<Arg, A, E, R, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> extends CommandProps<A, E, Id, I18nKey, State> {
|
|
118
118
|
new (): {};
|
|
119
119
|
/** click handlers */
|
|
120
|
-
handle: ((
|
|
120
|
+
handle: ((arg: Arg) => RuntimeFiber<Exit.Exit<A, E>, never>) & {
|
|
121
121
|
/** @deprecated don't exist */
|
|
122
|
-
effect: (
|
|
122
|
+
effect: (arg: Arg) => Effect.Effect<A, E, R>;
|
|
123
123
|
};
|
|
124
124
|
}
|
|
125
|
-
|
|
125
|
+
interface CommandContextLocal2<Id extends string, I18nKey extends string, State extends IntlRecord | undefined> extends CommandContextLocal<Id, I18nKey> {
|
|
126
|
+
state: State;
|
|
127
|
+
}
|
|
128
|
+
type CommandOutHelper<Arg, Eff extends Effect.Effect<any, any, any>, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> = CommandOut<Arg, Effect.Effect.Success<Eff>, Effect.Effect.Error<Eff>, Effect.Effect.Context<Eff>, Id, I18nKey, State>;
|
|
126
129
|
type Gen<RT, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> = {
|
|
127
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>, AEff,
|
|
130
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>, AEff, Arg = void>(body: (arg: Arg) => Generator<Eff, AEff, never>): CommandOut<Arg, AEff, [
|
|
128
131
|
Eff
|
|
129
132
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
130
133
|
Eff
|
|
131
134
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never, Id, I18nKey, State>;
|
|
132
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
135
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
133
136
|
Eff
|
|
134
137
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
135
138
|
Eff
|
|
136
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
137
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
139
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A): CommandOutHelper<Arg, A, Id, I18nKey, State>;
|
|
140
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
138
141
|
Eff
|
|
139
142
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
140
143
|
Eff
|
|
141
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
142
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
144
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B): CommandOutHelper<Arg, B, Id, I18nKey, State>;
|
|
145
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
143
146
|
Eff
|
|
144
147
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
145
148
|
Eff
|
|
146
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
147
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
149
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C): CommandOutHelper<Arg, C, Id, I18nKey, State>;
|
|
150
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
148
151
|
Eff
|
|
149
152
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
150
153
|
Eff
|
|
151
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
152
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
154
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D): CommandOutHelper<Arg, D, Id, I18nKey, State>;
|
|
155
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D, E extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
153
156
|
Eff
|
|
154
157
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
155
158
|
Eff
|
|
156
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
157
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
159
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E): CommandOutHelper<Arg, E, Id, I18nKey, State>;
|
|
160
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D, E, F extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
158
161
|
Eff
|
|
159
162
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
160
163
|
Eff
|
|
161
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
162
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
164
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F): CommandOutHelper<Arg, F, Id, I18nKey, State>;
|
|
165
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D, E, F, G extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
163
166
|
Eff
|
|
164
167
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
165
168
|
Eff
|
|
166
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
167
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
169
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G): CommandOutHelper<Arg, G, Id, I18nKey, State>;
|
|
170
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D, E, F, G, H extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
168
171
|
Eff
|
|
169
172
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
170
173
|
Eff
|
|
171
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
172
|
-
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff,
|
|
174
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, h: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H): CommandOutHelper<Arg, H, Id, I18nKey, State>;
|
|
175
|
+
<Eff extends YieldWrap<Effect.Effect<any, any, any>>, AEff, A, B, C, D, E, F, G, H, I extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Generator<Eff, AEff, never>, a: (_: Effect.Effect<AEff, [
|
|
173
176
|
Eff
|
|
174
177
|
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer E, infer _R>>] ? E : never, [
|
|
175
178
|
Eff
|
|
176
|
-
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>,
|
|
179
|
+
] extends [never] ? never : [Eff] extends [YieldWrap<Effect.Effect<infer _A, infer _E, infer R>>] ? R : never>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, h: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, i: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => I): CommandOutHelper<Arg, I, Id, I18nKey, State>;
|
|
177
180
|
};
|
|
178
181
|
type NonGen<RT, Id extends string, I18nKey extends string, State extends IntlRecord | undefined> = {
|
|
179
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>,
|
|
180
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A,
|
|
181
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B,
|
|
182
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C,
|
|
183
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D,
|
|
184
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E,
|
|
185
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F,
|
|
186
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G,
|
|
187
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G, H,
|
|
188
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G, H, I,
|
|
182
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
183
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
184
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
185
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
186
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
187
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
188
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
189
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
190
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G, H, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, h: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
191
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, A, B, C, D, E, F, G, H, I, Arg = void>(body: (arg: Arg, ctx: CommandContextLocal2<Id, I18nKey, State>) => A, a: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, h: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => I, i: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
189
192
|
};
|
|
190
|
-
type GenWrap<RT, Id extends string, I18nKey extends string,
|
|
191
|
-
(): Exclude<REff, RT> extends never ? CommandOut<
|
|
192
|
-
<A extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
193
|
-
<A, B extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
194
|
-
<A, B, C extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
195
|
-
<A, B, C, D extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
196
|
-
<A, B, C, D, E extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
197
|
-
<A, B, C, D, E, F extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
198
|
-
<A, B, C, D, E, F, G extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
199
|
-
<A, B, C, D, E, F, G, H extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
200
|
-
<A, B, C, D, E, F, G, H, I extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>,
|
|
193
|
+
type GenWrap<RT, Id extends string, I18nKey extends string, Arg, AEff, EEff, REff, State extends IntlRecord | undefined> = {
|
|
194
|
+
(): Exclude<REff, RT> extends never ? CommandOut<Arg, AEff, EEff, REff, Id, I18nKey, State> : MissingDependencies<RT, REff> & {};
|
|
195
|
+
<A extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A): CommandOutHelper<Arg, A, Id, I18nKey, State>;
|
|
196
|
+
<A, B extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B): CommandOutHelper<Arg, B, Id, I18nKey, State>;
|
|
197
|
+
<A, B, C extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C): CommandOutHelper<Arg, C, Id, I18nKey, State>;
|
|
198
|
+
<A, B, C, D extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D): CommandOutHelper<Arg, D, Id, I18nKey, State>;
|
|
199
|
+
<A, B, C, D, E extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E): CommandOutHelper<Arg, E, Id, I18nKey, State>;
|
|
200
|
+
<A, B, C, D, E, F extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F): CommandOutHelper<Arg, F, Id, I18nKey, State>;
|
|
201
|
+
<A, B, C, D, E, F, G extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G): CommandOutHelper<Arg, G, Id, I18nKey, State>;
|
|
202
|
+
<A, B, C, D, E, F, G, H extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, h: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H): CommandOutHelper<Arg, H, Id, I18nKey, State>;
|
|
203
|
+
<A, B, C, D, E, F, G, H, I extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => A, b: (_: A, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, c: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, d: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, e: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, f: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, g: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, h: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, i: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => I): CommandOutHelper<Arg, I, Id, I18nKey, State>;
|
|
201
204
|
};
|
|
202
|
-
type NonGenWrap<RT, Id extends string, I18nKey extends string,
|
|
203
|
-
(): Exclude<REff, RT> extends never ? CommandOutHelper<
|
|
204
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>,
|
|
205
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B,
|
|
206
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C,
|
|
207
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D,
|
|
208
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E,
|
|
209
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F,
|
|
210
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G,
|
|
211
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G, H,
|
|
212
|
-
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G, H, I,
|
|
205
|
+
type NonGenWrap<RT, Id extends string, I18nKey extends string, Arg, AEff, EEff, REff, State extends IntlRecord | undefined> = {
|
|
206
|
+
(): Exclude<REff, RT> extends never ? CommandOutHelper<Arg, Effect.Effect<AEff, EEff, REff>, Id, I18nKey, State> : MissingDependencies<RT, REff> & {};
|
|
207
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
208
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
209
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
210
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
211
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
212
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
213
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
214
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G, H, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, h: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
215
|
+
<Eff extends Effect.Effect<any, any, RT | CommandContext | `Commander.Command.${Id}.state`>, B, C, D, E, F, G, H, I, Arg>(a: (_: Effect.Effect<AEff, EEff, REff>, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => B, b: (_: B, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => C, c: (_: C, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => D, d: (_: D, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => E, e: (_: E, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => F, f: (_: F, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => G, g: (_: G, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => H, h: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => I, i: (_: H, arg: NoInfer<Arg>, ctx: CommandContextLocal2<NoInfer<Id>, NoInfer<I18nKey>, NoInfer<State>>) => Eff): CommandOutHelper<Arg, Eff, Id, I18nKey, State>;
|
|
213
216
|
};
|
|
214
217
|
}
|
|
215
218
|
type ErrorRenderer<E, Args extends readonly any[]> = (e: E, action: string, ...args: Args) => string | undefined;
|
|
@@ -236,8 +239,12 @@ export declare const CommanderStatic: {
|
|
|
236
239
|
* If you provide an `errorRenderer`, it will be used to render errors in the failure message.
|
|
237
240
|
*/
|
|
238
241
|
withDefaultToast: <A, E, R, Args extends Array<unknown>>(options?: {
|
|
242
|
+
/**
|
|
243
|
+
* if true, previous toasts with this key will be replaced
|
|
244
|
+
*/
|
|
245
|
+
stableToastId?: undefined | true | string | ((id: string, ...args: Args) => true | string | undefined);
|
|
239
246
|
errorRenderer?: ErrorRenderer<E, Args>;
|
|
240
|
-
onWaiting?: null | undefined | string | ((
|
|
247
|
+
onWaiting?: null | undefined | string | ((id: string, ...args: Args) => string | null | undefined);
|
|
241
248
|
onSuccess?: null | undefined | string | ((a: A, action: string, ...args: Args) => string | null | undefined);
|
|
242
249
|
}) => (self: Effect.Effect<A, E, R>, ...args: Args) => Effect.Effect<A, E, I18n | WithToast | CommandContext | R>;
|
|
243
250
|
};
|
|
@@ -257,7 +264,7 @@ export declare class CommanderImpl<RT> {
|
|
|
257
264
|
};
|
|
258
265
|
readonly makeCommand: <const Id extends string, const State extends IntlRecord | undefined, const I18nKey extends string = Id>(id_: Id | {
|
|
259
266
|
id: Id;
|
|
260
|
-
}, options?: FnOptions<I18nKey, State>, errorDef?: Error) => (<
|
|
267
|
+
}, options?: FnOptions<I18nKey, State>, errorDef?: Error) => (<Arg, A, E, R extends RT | CommandContext | `Commander.Command.${Id}.state`>(handler: (arg: Arg, ctx: Commander.CommandContextLocal2<Id, I18nKey, State>) => Effect.Effect<A, E, R>) => {
|
|
261
268
|
id: import("vue").UnwrapRef<Id>;
|
|
262
269
|
i18nKey: string;
|
|
263
270
|
namespace: string;
|
|
@@ -267,7 +274,7 @@ export declare class CommanderImpl<RT> {
|
|
|
267
274
|
action: string;
|
|
268
275
|
label: string;
|
|
269
276
|
state: State;
|
|
270
|
-
handle: ((
|
|
277
|
+
handle: ((arg: Arg) => RuntimeFiber<Exit.Exit<A, E>, never>) & {
|
|
271
278
|
action: ComputedRef<string>;
|
|
272
279
|
label: ComputedRef<string>;
|
|
273
280
|
};
|
|
@@ -306,17 +313,17 @@ export declare class CommanderImpl<RT> {
|
|
|
306
313
|
}, options?: FnOptions<I18nKey, State>) => Commander.Gen<RT, Id, I18nKey, State> & Commander.NonGen<RT, Id, I18nKey, State> & {
|
|
307
314
|
state: Context.Tag<`Commander.Command.${Id}.state`, State>;
|
|
308
315
|
};
|
|
309
|
-
/** @experimental */
|
|
310
|
-
alt2: <const Id extends string,
|
|
316
|
+
/** @experimental @deprecated */
|
|
317
|
+
alt2: <const Id extends string, MutArg, MutA, MutE, MutR, const I18nKey extends string = Id, State extends IntlRecord | undefined = undefined>(id: Id | {
|
|
311
318
|
id: Id;
|
|
312
|
-
mutate: (
|
|
313
|
-
} | (((
|
|
319
|
+
mutate: (arg: MutArg) => Effect.Effect<MutA, MutE, MutR>;
|
|
320
|
+
} | (((arg: MutArg) => Effect.Effect<MutA, MutE, MutR>) & {
|
|
314
321
|
id: Id;
|
|
315
|
-
}), options?: FnOptions<I18nKey, State>) => Commander.CommandContextLocal<Id, I18nKey> & (<
|
|
316
|
-
mutate: (
|
|
317
|
-
}) => (
|
|
322
|
+
}), options?: FnOptions<I18nKey, State>) => Commander.CommandContextLocal<Id, I18nKey> & (<A, E, R extends RT | CommandContext | `Commander.Command.${Id}.state`, Arg = void>(handler: (ctx: Effect.fn.Gen & Effect.fn.NonGen & Commander.CommandContextLocal<Id, I18nKey> & {
|
|
323
|
+
mutate: (arg: Arg) => Effect.Effect<MutA, MutE, MutR>;
|
|
324
|
+
}) => (arg: Arg, ctx: Commander.CommandContextLocal2<Id, I18nKey, State>) => Effect.Effect<A, E, R>) => Commander.CommandOut<Arg, A, E, R, Id, I18nKey, State>);
|
|
318
325
|
/** @experimental */
|
|
319
|
-
alt: <const Id extends string, const I18nKey extends string = Id, State extends IntlRecord | undefined = undefined>(id: Id, customI18nKey?: I18nKey) => Commander.CommandContextLocal<Id, I18nKey> & (<
|
|
326
|
+
alt: <const Id extends string, const I18nKey extends string = Id, State extends IntlRecord | undefined = undefined>(id: Id, customI18nKey?: I18nKey) => Commander.CommandContextLocal<Id, I18nKey> & (<A, E, R extends RT | CommandContext | `Commander.Command.${Id}.state`, Arg = void>(handler: (arg: Arg, ctx: Commander.CommandContextLocal2<Id, I18nKey, State>) => Effect.Effect<A, E, R>) => Commander.CommandOut<Arg, A, E, R, Id, I18nKey, State>);
|
|
320
327
|
/**
|
|
321
328
|
* Define a Command for handling user actions with built-in error reporting and state management.
|
|
322
329
|
*
|
|
@@ -344,12 +351,12 @@ export declare class CommanderImpl<RT> {
|
|
|
344
351
|
* **User Feedback**: Use the `withDefaultToast` helper for status notifications, or render
|
|
345
352
|
* the `result` inline for custom UI feedback.
|
|
346
353
|
*/
|
|
347
|
-
wrap: <const Id extends string,
|
|
348
|
-
mutate: (
|
|
354
|
+
wrap: <const Id extends string, Arg, A, E, R, const State extends IntlRecord = IntlRecord, I18nKey extends string = Id>(mutation: {
|
|
355
|
+
mutate: (arg: Arg) => Effect.Effect<A, E, R>;
|
|
349
356
|
id: Id;
|
|
350
|
-
} | (((
|
|
357
|
+
} | (((arg: Arg) => Effect.Effect<A, E, R>) & {
|
|
351
358
|
id: Id;
|
|
352
|
-
}), options?: FnOptions<I18nKey, State>) => Commander.CommanderWrap<RT, Id, I18nKey, State,
|
|
359
|
+
}), options?: FnOptions<I18nKey, State>) => Commander.CommanderWrap<RT, Id, I18nKey, State, Arg, A, E, R>;
|
|
353
360
|
}
|
|
354
361
|
declare const Commander_base: Effect.Service.Class<Commander, "Commander", {
|
|
355
362
|
readonly dependencies: readonly [import("effect/Layer").Layer<WithToast, never, import("./toast.js").Toast>, import("effect/Layer").Layer<Confirm, never, I18n>];
|