@sealcode/sealgen 0.18.7 → 0.18.8
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/@types/forms/controls/array.d.ts +0 -1
- package/@types/forms/controls/derived-frame.d.ts +0 -1
- package/@types/forms/controls/form-control.d.ts +0 -1
- package/@types/forms/controls/multiple-files.d.ts +0 -1
- package/@types/forms/controls/table.d.ts +0 -1
- package/@types/forms/form.d.ts +0 -1
- package/@types/forms/multiform.d.ts +0 -1
- package/@types/mount.d.ts +0 -1
- package/@types/page/mountable.d.ts +0 -1
- package/@types/page/page.d.ts +0 -1
- package/@types/page/stateful-page.d.ts +0 -1
- package/package.json +1 -1
- package/.xunit +0 -70
- package/@types/remove-named-imports.d.ts +0 -5
- package/@types/src/CSSBuilder.d.ts +0 -19
- package/@types/src/add-collection.d.ts +0 -1
- package/@types/src/add-crud.d.ts +0 -3
- package/@types/src/add-jdd-component.d.ts +0 -1
- package/@types/src/add-list-route.test.d.ts +0 -1
- package/@types/src/add-route.d.ts +0 -3
- package/@types/src/add-route.test.d.ts +0 -1
- package/@types/src/add-verbose-crud.d.ts +0 -3
- package/@types/src/build.d.ts +0 -3
- package/@types/src/builder.d.ts +0 -35
- package/@types/src/builders/backend-ts-builder.d.ts +0 -7
- package/@types/src/builders/builder.d.ts +0 -11
- package/@types/src/builders/colors-builder.d.ts +0 -10
- package/@types/src/builders/css-builder.d.ts +0 -19
- package/@types/src/builders/fonts-builder.d.ts +0 -7
- package/@types/src/builders/frontend-ts-builder.d.ts +0 -11
- package/@types/src/cli.d.ts +0 -2
- package/@types/src/components/components.d.ts +0 -2
- package/@types/src/components/tabs.d.ts +0 -2
- package/@types/src/components/toggle-modal.d.ts +0 -6
- package/@types/src/crud-field-snippets.d.ts +0 -3
- package/@types/src/embeddable-file-extensions.d.ts +0 -1
- package/@types/src/esbuild-plugins/load-assets.d.ts +0 -5
- package/@types/src/esbuild-plugins/rewrite-asset-imports.d.ts +0 -5
- package/@types/src/example.test.d.ts +0 -1
- package/@types/src/find-css-includes.d.ts +0 -1
- package/@types/src/forms/controls/array.d.ts +0 -35
- package/@types/src/forms/controls/autocomplete.d.ts +0 -22
- package/@types/src/forms/controls/big-radio-group.d.ts +0 -14
- package/@types/src/forms/controls/checkbox-group.d.ts +0 -21
- package/@types/src/forms/controls/checkbox.d.ts +0 -17
- package/@types/src/forms/controls/checkboxed-list-input.d.ts +0 -21
- package/@types/src/forms/controls/checkboxed-list-input.test.d.ts +0 -1
- package/@types/src/forms/controls/collapsible-checkbox-group.d.ts +0 -11
- package/@types/src/forms/controls/collapsible-field-group.d.ts +0 -21
- package/@types/src/forms/controls/controls.d.ts +0 -31
- package/@types/src/forms/controls/derived-frame.d.ts +0 -21
- package/@types/src/forms/controls/derived.d.ts +0 -13
- package/@types/src/forms/controls/dropdown.d.ts +0 -30
- package/@types/src/forms/controls/editable-collection-subset.d.ts +0 -20
- package/@types/src/forms/controls/field-group.d.ts +0 -23
- package/@types/src/forms/controls/file.d.ts +0 -13
- package/@types/src/forms/controls/file.test.d.ts +0 -1
- package/@types/src/forms/controls/form-control.d.ts +0 -20
- package/@types/src/forms/controls/form-field-control.d.ts +0 -13
- package/@types/src/forms/controls/form-header.d.ts +0 -8
- package/@types/src/forms/controls/form-paragraph.d.ts +0 -7
- package/@types/src/forms/controls/frame.d.ts +0 -17
- package/@types/src/forms/controls/hidden-input.d.ts +0 -9
- package/@types/src/forms/controls/html.d.ts +0 -11
- package/@types/src/forms/controls/multiple-files.d.ts +0 -40
- package/@types/src/forms/controls/multiple-photos.d.ts +0 -19
- package/@types/src/forms/controls/number.d.ts +0 -13
- package/@types/src/forms/controls/photo.d.ts +0 -21
- package/@types/src/forms/controls/photo.test.d.ts +0 -1
- package/@types/src/forms/controls/radio.d.ts +0 -16
- package/@types/src/forms/controls/reverse-single-reference.d.ts +0 -1
- package/@types/src/forms/controls/simple-input.d.ts +0 -33
- package/@types/src/forms/controls/single-reference.d.ts +0 -13
- package/@types/src/forms/controls/single-reference.test.d.ts +0 -1
- package/@types/src/forms/controls/table.d.ts +0 -34
- package/@types/src/forms/controls/textarea.d.ts +0 -25
- package/@types/src/forms/controls/tickable.d.ts +0 -25
- package/@types/src/forms/fields/boolean.d.ts +0 -17
- package/@types/src/forms/fields/boolean.test.d.ts +0 -1
- package/@types/src/forms/fields/checkboxed-list.d.ts +0 -21
- package/@types/src/forms/fields/collection-field.d.ts +0 -15
- package/@types/src/forms/fields/email.d.ts +0 -7
- package/@types/src/forms/fields/email.test.d.ts +0 -1
- package/@types/src/forms/fields/enum-multiple.d.ts +0 -18
- package/@types/src/forms/fields/enum-multiple.test.d.ts +0 -1
- package/@types/src/forms/fields/enum.d.ts +0 -18
- package/@types/src/forms/fields/enum.test.d.ts +0 -1
- package/@types/src/forms/fields/existing-sealious-value.d.ts +0 -6
- package/@types/src/forms/fields/field.d.ts +0 -48
- package/@types/src/forms/fields/field.test.d.ts +0 -1
- package/@types/src/forms/fields/fields.d.ts +0 -16
- package/@types/src/forms/fields/file.d.ts +0 -19
- package/@types/src/forms/fields/file.test.d.ts +0 -1
- package/@types/src/forms/fields/multiple-files.d.ts +0 -14
- package/@types/src/forms/fields/number.d.ts +0 -23
- package/@types/src/forms/fields/number.test.d.ts +0 -1
- package/@types/src/forms/fields/pick-from-list.d.ts +0 -14
- package/@types/src/forms/fields/pick-from-list.test.d.ts +0 -1
- package/@types/src/forms/fields/proxy-field.d.ts +0 -13
- package/@types/src/forms/fields/regexp.d.ts +0 -16
- package/@types/src/forms/fields/regexp.test.d.ts +0 -1
- package/@types/src/forms/fields/reverse-single-reference.d.ts +0 -13
- package/@types/src/forms/fields/simple-form-field.d.ts +0 -9
- package/@types/src/forms/fields/structured-array.d.ts +0 -14
- package/@types/src/forms/fields/table.d.ts +0 -13
- package/@types/src/forms/form-types.d.ts +0 -26
- package/@types/src/forms/form.d.ts +0 -31
- package/@types/src/forms/form.test.d.ts +0 -6
- package/@types/src/forms/multiform.d.ts +0 -24
- package/@types/src/forms/multiform.test.d.ts +0 -1
- package/@types/src/generate-collections.d.ts +0 -2
- package/@types/src/generate-components.d.ts +0 -1
- package/@types/src/generate-routes.d.ts +0 -5
- package/@types/src/generate-routes.test.d.ts +0 -1
- package/@types/src/generate-stimulus.d.ts +0 -1
- package/@types/src/get-fonts.d.ts +0 -2
- package/@types/src/index.d.ts +0 -46
- package/@types/src/make-env.d.ts +0 -1
- package/@types/src/make-hidden-inputs.d.ts +0 -5
- package/@types/src/mount.d.ts +0 -7
- package/@types/src/notifier.d.ts +0 -2
- package/@types/src/page/access-control.d.ts +0 -6
- package/@types/src/page/default-list-filters.d.ts +0 -18
- package/@types/src/page/list.d.ts +0 -48
- package/@types/src/page/mountable-with-fields.d.ts +0 -42
- package/@types/src/page/mountable-with-fields.test.d.ts +0 -1
- package/@types/src/page/mountable.d.ts +0 -11
- package/@types/src/page/page.d.ts +0 -19
- package/@types/src/page/props-parser.d.ts +0 -16
- package/@types/src/page/sealious-list.d.ts +0 -20
- package/@types/src/page/sealious-list.test.d.ts +0 -1
- package/@types/src/page/stateful-page.d.ts +0 -63
- package/@types/src/page/stateful-page.test.d.ts +0 -1
- package/@types/src/register-external.d.ts +0 -2
- package/@types/src/register-external.test.d.ts +0 -1
- package/@types/src/run.d.ts +0 -1
- package/@types/src/sanitize.d.ts +0 -1
- package/@types/src/target-locreq.d.ts +0 -4
- package/@types/src/templates/collection.d.ts +0 -1
- package/@types/src/templates/form.d.ts +0 -16
- package/@types/src/templates/jdd-component.d.ts +0 -1
- package/@types/src/templates/jdd-editor.d.ts +0 -1
- package/@types/src/templates/list.d.ts +0 -1
- package/@types/src/templates/long-running-process.d.ts +0 -1
- package/@types/src/templates/multiform.d.ts +0 -1
- package/@types/src/templates/page.d.ts +0 -1
- package/@types/src/templates/post.d.ts +0 -1
- package/@types/src/templates/redirect.d.ts +0 -1
- package/@types/src/templates/route-test.d.ts +0 -1
- package/@types/src/templates/shared/collection-create-form.d.ts +0 -1
- package/@types/src/templates/shared/collection-edit-form.d.ts +0 -1
- package/@types/src/templates/shared/collection-list.d.ts +0 -16
- package/@types/src/templates/shared/confirm-item-delete.d.ts +0 -1
- package/@types/src/templates/shared/handlers/boolean.d.ts +0 -2
- package/@types/src/templates/shared/handlers/date.d.ts +0 -2
- package/@types/src/templates/shared/handlers/deep-reverse-single-reference.d.ts +0 -2
- package/@types/src/templates/shared/handlers/default.d.ts +0 -2
- package/@types/src/templates/shared/handlers/enum.d.ts +0 -2
- package/@types/src/templates/shared/handlers/file.d.ts +0 -2
- package/@types/src/templates/shared/handlers/image.d.ts +0 -2
- package/@types/src/templates/shared/handlers/int.d.ts +0 -2
- package/@types/src/templates/shared/handlers/jdd.d.ts +0 -2
- package/@types/src/templates/shared/handlers/settable-by.d.ts +0 -2
- package/@types/src/templates/shared/handlers/single-reference.d.ts +0 -2
- package/@types/src/templates/shared/handlers/structured-array.d.ts +0 -2
- package/@types/src/templates/shared/item-delete.d.ts +0 -1
- package/@types/src/templates/shared/shared-crud-form-fields.d.ts +0 -68
- package/@types/src/templates/stateful-page.d.ts +0 -1
- package/@types/src/templates/stimulus-controller.d.ts +0 -1
- package/@types/src/templates/templates.d.ts +0 -21
- package/@types/src/test_utils/exec_async.d.ts +0 -1
- package/@types/src/test_utils/locator_is_visible.d.ts +0 -2
- package/@types/src/test_utils/test-on-real-app.d.ts +0 -27
- package/@types/src/utils/assert-throws.d.ts +0 -1
- package/@types/src/utils/base64.d.ts +0 -2
- package/@types/src/utils/browser-creator.d.ts +0 -1
- package/@types/src/utils/escape-url-params.d.ts +0 -2
- package/@types/src/utils/exec.d.ts +0 -5
- package/@types/src/utils/extract-fields-from-collection.d.ts +0 -14
- package/@types/src/utils/format-external-url.d.ts +0 -1
- package/@types/src/utils/import-path.d.ts +0 -2
- package/@types/src/utils/input-wrapper.d.ts +0 -3
- package/@types/src/utils/list-collections.d.ts +0 -1
- package/@types/src/utils/make-slug.d.ts +0 -1
- package/@types/src/utils/module-dirname.d.ts +0 -1
- package/@types/src/utils/natural-numbers.d.ts +0 -1
- package/@types/src/utils/prettier.d.ts +0 -3
- package/@types/src/utils/question.d.ts +0 -1
- package/@types/src/utils/render-attributes.d.ts +0 -1
- package/@types/src/utils/sleep.d.ts +0 -1
- package/@types/src/utils/translate.d.ts +0 -3
- package/@types/src/utils/url-with-new-params.d.ts +0 -2
- package/@types/src/utils/utils.d.ts +0 -17
- package/@types/src/utils/walk.d.ts +0 -1
- package/@types/src/utils/with-fallback.d.ts +0 -2
- package/@types/src/utils/write-file.d.ts +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/// <reference types="koa__router" resolution-mode="require"/>
|
|
2
|
-
import Router from "@koa/router";
|
|
3
|
-
import { Context } from "koa";
|
|
4
|
-
import { Templatable } from "tempstream";
|
|
5
|
-
import { Mountable } from "./mountable.js";
|
|
6
|
-
export type StatefulPageActionDescription<ActionName> = {
|
|
7
|
-
action: ActionName;
|
|
8
|
-
label?: string;
|
|
9
|
-
content?: string;
|
|
10
|
-
disabled?: boolean;
|
|
11
|
-
} | ActionName;
|
|
12
|
-
export type StateAndMetadata<State, Actions> = {
|
|
13
|
-
state: State;
|
|
14
|
-
inputs: Record<string, string>;
|
|
15
|
-
action: keyof Actions;
|
|
16
|
-
action_args: string;
|
|
17
|
-
} | {
|
|
18
|
-
state: State;
|
|
19
|
-
inputs: Record<string, string>;
|
|
20
|
-
action: null;
|
|
21
|
-
action_args: null;
|
|
22
|
-
$: Record<string, unknown>;
|
|
23
|
-
};
|
|
24
|
-
export type StatefulPageActionArgument<State extends Record<string, unknown>, Args extends unknown[] = unknown[]> = {
|
|
25
|
-
ctx: Context;
|
|
26
|
-
state: State;
|
|
27
|
-
inputs: Record<string, string>;
|
|
28
|
-
args: Args;
|
|
29
|
-
page: StatefulPage<any, any>;
|
|
30
|
-
};
|
|
31
|
-
export type StatefulPageAction<State extends Record<string, unknown>, Args extends unknown[] = unknown[]> = (obj: StatefulPageActionArgument<State, Args>) => State | Promise<State>;
|
|
32
|
-
export type ExtractStatefulPageActionArgs<X> = X extends StatefulPageAction<any, infer Args> ? Args : never;
|
|
33
|
-
export declare abstract class StatefulPage<State extends Record<string, unknown>, Actions extends Record<string, StatefulPageAction<State>>> extends Mountable {
|
|
34
|
-
abstract actions: Actions;
|
|
35
|
-
abstract getInitialState(ctx: Context): State | Promise<State>;
|
|
36
|
-
abstract render(ctx: Context, state: State, inputs: Record<string, string>): Templatable | Promise<Templatable>;
|
|
37
|
-
canAccess(_ctx: Context): Promise<{
|
|
38
|
-
canAccess: boolean;
|
|
39
|
-
message: string;
|
|
40
|
-
}>;
|
|
41
|
-
constructor();
|
|
42
|
-
abstract wrapInLayout(ctx: Context, content: Templatable, state: State): Templatable;
|
|
43
|
-
wrapInForm(context: Context, state: State, content: Templatable): Promise<Templatable>;
|
|
44
|
-
extractActionAndLabel<ActionName extends keyof Actions>(action_description: StatefulPageActionDescription<ActionName>): {
|
|
45
|
-
action: string;
|
|
46
|
-
label: string;
|
|
47
|
-
content: string;
|
|
48
|
-
disabled: boolean;
|
|
49
|
-
};
|
|
50
|
-
makeActionURL<ActionName extends keyof Actions>(action_description: StatefulPageActionDescription<ActionName>, ...args: ExtractStatefulPageActionArgs<Actions[ActionName]>): string;
|
|
51
|
-
makeActionButton<ActionName extends keyof Actions>(_state: State, action_description: StatefulPageActionDescription<ActionName>, ...args: ExtractStatefulPageActionArgs<Actions[ActionName]>): string;
|
|
52
|
-
makeActionCallback<ActionName extends keyof Actions>(action_description: {
|
|
53
|
-
action: ActionName;
|
|
54
|
-
label?: string;
|
|
55
|
-
} | ActionName, ...args: ExtractStatefulPageActionArgs<Actions[ActionName]>): string;
|
|
56
|
-
rerender(): string;
|
|
57
|
-
preprocessState(values: State): Promise<State>;
|
|
58
|
-
preprocessOverrides(_context: Context, _state: State, values: Record<string, unknown>): Promise<Record<string, unknown>>;
|
|
59
|
-
serializeState(_context: Context, state: State): Promise<string>;
|
|
60
|
-
deserializeState(_context: Context, s: string): Promise<State>;
|
|
61
|
-
extractState(ctx: Context): Promise<StateAndMetadata<State, Actions>>;
|
|
62
|
-
mount(router: Router, path: string): void;
|
|
63
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/@types/src/run.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/@types/src/sanitize.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function attribute(raw: string | number): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function collectionTemplate(collection_name: string, fields_string?: string): string;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
declare const defaults: {
|
|
2
|
-
postimport: string;
|
|
3
|
-
fields: string;
|
|
4
|
-
controls: string;
|
|
5
|
-
validate_method: string;
|
|
6
|
-
onsubmit: string;
|
|
7
|
-
can_access: string;
|
|
8
|
-
render: string;
|
|
9
|
-
get_initial_values: string;
|
|
10
|
-
other_methods: string;
|
|
11
|
-
success_message: string;
|
|
12
|
-
};
|
|
13
|
-
export declare function formTemplate(action_name: string, newfilefullpath: string, _params?: Partial<typeof defaults> & {
|
|
14
|
-
success_message: string;
|
|
15
|
-
}): Promise<string>;
|
|
16
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function jddComponentTemplate(component_name: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function jddEditorTemplate(actionName: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const listTemplate: (action_name: string, newfilefullpath: string) => Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function LongRunningProcessTemplate(action_name: string, newfilefullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function multiformTemplate(action_name: string, newfilefullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function pageTemplate(action_name: string, newfilefullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function postTemplate(action_name: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function redirectTemplate(action_name: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function testTemplate(action_name: string, new_file_fullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function createItemFormTemplate(create_action_name: string, newfilefullpath: string, collection_name: string, list_action: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function editItemFormTemplate(edit_action_name: string, newfilefullpath: string, collection_name: string, list_action: string): Promise<string>;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export declare function makeDefaultFilterFields(collection_fields: {
|
|
2
|
-
name: string;
|
|
3
|
-
type: string;
|
|
4
|
-
}[]): string;
|
|
5
|
-
export declare function makeDefaultDisplayFields(collection_fields: {
|
|
6
|
-
name: string;
|
|
7
|
-
type: string;
|
|
8
|
-
}[]): string;
|
|
9
|
-
declare const default_hooks: {
|
|
10
|
-
pre_header_html: string;
|
|
11
|
-
post_header_html: string;
|
|
12
|
-
post_import_js: string;
|
|
13
|
-
render_item: (collection_name: string) => string;
|
|
14
|
-
};
|
|
15
|
-
export declare function collectionListTemplate(collection_name: string, action_name: string, _: string, _hooks?: Partial<typeof default_hooks>): Promise<string>;
|
|
16
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function askItemDeleteTemplate(ask_delete_action_name: string, collection_name: string, newfilefullpath: string, list_action_name: string, delete_action_name: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function itemDeleteTemplate(delete_action_name: string, collection_name: string, list_action_name: string, importPath: (path: string) => string): Promise<string>;
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { ExtractedFieldInfo } from "../../utils/extract-fields-from-collection.js";
|
|
2
|
-
export type FieldHandlerResult = {
|
|
3
|
-
imports: Partial<{
|
|
4
|
-
shared: string;
|
|
5
|
-
edit: string;
|
|
6
|
-
}>;
|
|
7
|
-
hide_field: boolean;
|
|
8
|
-
field: string;
|
|
9
|
-
hide_control: boolean;
|
|
10
|
-
controls: string;
|
|
11
|
-
is_required: boolean;
|
|
12
|
-
is_required_expr: string;
|
|
13
|
-
fields_var: string;
|
|
14
|
-
top_level_shared: string;
|
|
15
|
-
name: string;
|
|
16
|
-
hide_initial_value_edit: boolean;
|
|
17
|
-
initial_value_edit: Partial<{
|
|
18
|
-
main_value: string;
|
|
19
|
-
parsed_value: string;
|
|
20
|
-
fallback_value: string;
|
|
21
|
-
}> | string;
|
|
22
|
-
hide_initial_value_create: boolean;
|
|
23
|
-
initial_value_create: string;
|
|
24
|
-
pre_edit: string;
|
|
25
|
-
post_edit: string;
|
|
26
|
-
pre_create: string;
|
|
27
|
-
post_create: string;
|
|
28
|
-
sealious_value: (result: Exclude<FieldHandlerResult, "sealious_value">) => string;
|
|
29
|
-
hide_sealious_value: boolean;
|
|
30
|
-
fallback_value_sealious: string;
|
|
31
|
-
main_value_sealious: string;
|
|
32
|
-
};
|
|
33
|
-
export type FieldHandler<Defaults extends Partial<FieldHandlerResult>, Result extends Partial<FieldHandlerResult>> = (collection_name: string, field: ExtractedFieldInfo, importPath: (path: string) => string, defaults: Defaults, all_other_handlers: Record<string, FieldHandler<FieldHandlerResult, Partial<FieldHandlerResult>> | undefined>, fields_var?: string) => Promise<Result>;
|
|
34
|
-
export declare const field_handlers: Record<Exclude<string, "default">, FieldHandler<FieldHandlerResult, Partial<FieldHandlerResult>> | undefined> & {
|
|
35
|
-
default: FieldHandler<Record<string, never>, FieldHandlerResult>;
|
|
36
|
-
};
|
|
37
|
-
export declare function getFieldHandler(collection_name: string, field: ExtractedFieldInfo, importPath: (path: string) => string, fields_var?: string): Promise<{
|
|
38
|
-
imports: Partial<{
|
|
39
|
-
shared: string;
|
|
40
|
-
edit: string;
|
|
41
|
-
}>;
|
|
42
|
-
hide_field: boolean;
|
|
43
|
-
field: string;
|
|
44
|
-
hide_control: boolean;
|
|
45
|
-
controls: string;
|
|
46
|
-
is_required: boolean;
|
|
47
|
-
is_required_expr: string;
|
|
48
|
-
fields_var: string;
|
|
49
|
-
top_level_shared: string;
|
|
50
|
-
name: string;
|
|
51
|
-
hide_initial_value_edit: boolean;
|
|
52
|
-
initial_value_edit: string | Partial<{
|
|
53
|
-
main_value: string;
|
|
54
|
-
parsed_value: string;
|
|
55
|
-
fallback_value: string;
|
|
56
|
-
}>;
|
|
57
|
-
hide_initial_value_create: boolean;
|
|
58
|
-
initial_value_create: string;
|
|
59
|
-
pre_edit: string;
|
|
60
|
-
post_edit: string;
|
|
61
|
-
pre_create: string;
|
|
62
|
-
post_create: string;
|
|
63
|
-
sealious_value: (result: FieldHandlerResult) => string;
|
|
64
|
-
hide_sealious_value: boolean;
|
|
65
|
-
fallback_value_sealious: string;
|
|
66
|
-
main_value_sealious: string;
|
|
67
|
-
}>;
|
|
68
|
-
export declare function sharedCrudFormFields(collection_name: string, newfilefullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function statefulPageTemplate(action_name: string, newfilefullpath: string): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function jddComponentTemplate(controller_name: string): string;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { formTemplate } from "./form.js";
|
|
2
|
-
import { jddComponentTemplate } from "./jdd-component.js";
|
|
3
|
-
import { LongRunningProcessTemplate } from "./long-running-process.js";
|
|
4
|
-
import { multiformTemplate } from "./multiform.js";
|
|
5
|
-
import { pageTemplate } from "./page.js";
|
|
6
|
-
import { postTemplate } from "./post.js";
|
|
7
|
-
import { redirectTemplate } from "./redirect.js";
|
|
8
|
-
import { statefulPageTemplate } from "./stateful-page.js";
|
|
9
|
-
import { jddEditorTemplate } from "./jdd-editor.js";
|
|
10
|
-
export declare const Templates: {
|
|
11
|
-
page: typeof pageTemplate;
|
|
12
|
-
form: typeof formTemplate;
|
|
13
|
-
list: (action_name: string, newfilefullpath: string) => Promise<string>;
|
|
14
|
-
multiform: typeof multiformTemplate;
|
|
15
|
-
redirect: typeof redirectTemplate;
|
|
16
|
-
post: typeof postTemplate;
|
|
17
|
-
sreact: typeof statefulPageTemplate;
|
|
18
|
-
lpr: typeof LongRunningProcessTemplate;
|
|
19
|
-
jdd: typeof jddComponentTemplate;
|
|
20
|
-
"jdd-editor": typeof jddEditorTemplate;
|
|
21
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const execAsync: (cmd: string) => Promise<void>;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
import EventEmitter from "events";
|
|
3
|
-
export declare const callSealgenBin: () => string;
|
|
4
|
-
export declare class RealAppTest {
|
|
5
|
-
node_pid: number;
|
|
6
|
-
app_port: number;
|
|
7
|
-
mongo_port: number;
|
|
8
|
-
app_path: string;
|
|
9
|
-
container_name: string;
|
|
10
|
-
emitter: EventEmitter<[never]>;
|
|
11
|
-
static init(): Promise<RealAppTest>;
|
|
12
|
-
start(): Promise<void>;
|
|
13
|
-
close(): Promise<void>;
|
|
14
|
-
runSealgenCommand(command: string): Promise<void>;
|
|
15
|
-
build(): Promise<void>;
|
|
16
|
-
throwIfItKillsTheApp<T>(cb: () => Promise<T>): Promise<T>;
|
|
17
|
-
httpGET(path: string): Promise<{
|
|
18
|
-
status: number;
|
|
19
|
-
response: string;
|
|
20
|
-
}>;
|
|
21
|
-
httpPOST(path: string, body: Record<string, unknown>): Promise<{
|
|
22
|
-
status: number;
|
|
23
|
-
response: string;
|
|
24
|
-
}>;
|
|
25
|
-
addFile(target_path: string, content: string): Promise<void>;
|
|
26
|
-
fullURL(path: string): string;
|
|
27
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function assertThrowsAsync(fn: () => Promise<unknown>, error_handler?: (e: unknown) => Promise<void> | void): Promise<void>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export function getBrowser(): Promise<any>;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export type ExtractedFieldInfo = {
|
|
2
|
-
name: string;
|
|
3
|
-
type: string;
|
|
4
|
-
target: string | null;
|
|
5
|
-
referencing_collection: string | null;
|
|
6
|
-
referencing_field: string | null;
|
|
7
|
-
intermediary_field_that_points_there: string | null;
|
|
8
|
-
is_readonly: boolean;
|
|
9
|
-
is_required: boolean;
|
|
10
|
-
subfields: {
|
|
11
|
-
name: string;
|
|
12
|
-
}[];
|
|
13
|
-
};
|
|
14
|
-
export default function extract_fields_from_collection(collection_name: string): Promise<ExtractedFieldInfo[]>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function formatExternalURL(url: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function listCollections(): Promise<string[]>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function makeSlug(t: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function module_dirname(module_url: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function naturalNumbers(min: number, max: number): Generator<number, void, unknown>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function question(text: string, validator: (answer: string) => boolean): Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function renderAttributes(attrs: Record<string, string | boolean>): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function sleep(time: number): Promise<unknown>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export type Awaited<T> = T extends Promise<infer U> ? U : T;
|
|
2
|
-
export type UnwrapArray<T> = T extends Array<infer U> ? U : T;
|
|
3
|
-
export declare function keys<S extends string>(object: Record<S, unknown>): S[];
|
|
4
|
-
export type ExtractTail<T extends any[]> = T extends [infer _, ...infer Tail] ? Tail : never;
|
|
5
|
-
export { sleep } from "./sleep.js";
|
|
6
|
-
export { naturalNumbers } from "./natural-numbers.js";
|
|
7
|
-
export { UrlWithNewParams } from "./url-with-new-params.js";
|
|
8
|
-
export { exec } from "./exec.js";
|
|
9
|
-
export { importPath, curryImportPath } from "./import-path.js";
|
|
10
|
-
export { listCollections } from "./list-collections.js";
|
|
11
|
-
export { walkDir } from "./walk.js";
|
|
12
|
-
export { assertThrowsAsync } from "./assert-throws.js";
|
|
13
|
-
export * from "./make-slug.js";
|
|
14
|
-
export * from "./render-attributes.js";
|
|
15
|
-
export * from "./format-external-url.js";
|
|
16
|
-
export * from "./base64.js";
|
|
17
|
-
export * from "./with-fallback.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function walkDir(dir: string): Promise<string[]>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function writeFile(path: string, content: string): Promise<void>;
|