Skip to content

Commit

Permalink
chore: ae up
Browse files Browse the repository at this point in the history
  • Loading branch information
matej21 committed Feb 21, 2024
1 parent a62f7b6 commit f395a54
Show file tree
Hide file tree
Showing 26 changed files with 2,441 additions and 856 deletions.
407 changes: 91 additions & 316 deletions build/api/admin.api.md

Large diffs are not rendered by default.

26 changes: 15 additions & 11 deletions build/api/binding.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,11 @@ export class EntityAccessor implements Errorable {
// (undocumented)
batchUpdates(performUpdates: EntityAccessor.BatchUpdatesHandler): void;
// (undocumented)
connectEntityAtField(field: FieldName, entityToConnect: EntityAccessor): void;
connectEntityAtField(field: SugaredRelativeSingleEntity | string, entityToConnect: EntityAccessor): void;
// (undocumented)
deleteEntity(): void;
// (undocumented)
disconnectEntityAtField(field: FieldName, initializeReplacement?: EntityAccessor.BatchUpdatesHandler): void;
disconnectEntityAtField(field: SugaredRelativeSingleEntity | string, initializeReplacement?: EntityAccessor.BatchUpdatesHandler): void;
// (undocumented)
readonly environment: Environment;
// (undocumented)
Expand Down Expand Up @@ -486,9 +486,9 @@ export class EntitySubTreeMarker {
}

// @public (undocumented)
export class Environment {
export class Environment<Node extends Environment.AnyNode | undefined = Environment.AnyNode | undefined> {
// (undocumented)
static create(): Environment;
static create(): Environment<Environment.AnyNode | undefined>;
// (undocumented)
getAllDimensions(): Environment.SelectedDimensions;
// (undocumented)
Expand All @@ -512,7 +512,7 @@ export class Environment {
// (undocumented)
getSubTree(): Environment.SubTreeNode;
// (undocumented)
getSubTreeNode(): Environment.AnyNode;
getSubTreeNode(): Node & Environment.AnyNode;
// @deprecated (undocumented)
getValue<V extends Environment.Value = Environment.Value>(key: string): V;
// @deprecated (undocumented)
Expand Down Expand Up @@ -542,9 +542,9 @@ export class Environment {
// (undocumented)
withSchema(schema: Schema): Environment;
// (undocumented)
withSubTree(SubTree: Environment.SubTreeNode): Environment;
withSubTree<Node extends Environment.SubTreeNode>(SubTree: Node): Environment<Node>;
// (undocumented)
withSubTreeChild(node: Environment.InnerNode): Environment;
withSubTreeChild<Node extends Environment.InnerNode>(node: Node): Environment<Node>;
// (undocumented)
withVariables(variables: Environment.ValuesMapWithFactory | undefined): Environment;
}
Expand Down Expand Up @@ -598,13 +598,13 @@ export namespace Environment {
// (undocumented)
export type Name = string;
// (undocumented)
export interface Options {
export interface Options<Node extends AnyNode | undefined> {
// (undocumented)
dimensions: SelectedDimensions;
// (undocumented)
extensions: Map<Extension<unknown, unknown>, unknown>;
// (undocumented)
node?: AnyNode;
node?: Node;
// (undocumented)
parameters: Parameters;
// (undocumented)
Expand Down Expand Up @@ -1861,15 +1861,19 @@ export class TreeAugmenter {
// @public (undocumented)
export class TreeNodeEnvironmentFactory {
// (undocumented)
static createEnvironmentForEntity(environment: Environment, sugaredRelativeSingleEntity: SugaredRelativeSingleEntity): Environment;
static createEnvironmentForEntity(environment: Environment, sugaredRelativeSingleEntity: SugaredRelativeSingleEntity): Environment<Environment.AnyNode | undefined>;
// (undocumented)
static createEnvironmentForEntityList(environment: Environment, sugaredRelativeEntityList: SugaredRelativeEntityList): Environment;
// (undocumented)
static createEnvironmentForEntityListSubtree(environment: Environment, sugaredEntityList: SugaredQualifiedEntityList | SugaredUnconstrainedQualifiedEntityList): Environment;
// (undocumented)
static createEnvironmentForEntitySubtree(environment: Environment, sugaredEntityList: SugaredQualifiedSingleEntity | SugaredUnconstrainedQualifiedSingleEntity): Environment;
// (undocumented)
static createEnvironmentForField(environment: Environment, sugaredRelativeSingleField: SugaredRelativeSingleField): Environment;
static createEnvironmentForField(environment: Environment, sugaredRelativeSingleField: SugaredRelativeSingleField): Environment<{
type: "column";
entity: SchemaEntity;
field: SchemaColumn;
}>;
}

// @public (undocumented)
Expand Down
4 changes: 4 additions & 0 deletions build/api/client-content.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import { GraphQlClient } from '@contember/graphql-client';
import { GraphQlClientRequestOptions } from '@contember/graphql-client';
import { GraphQlFieldTypedArgs } from '@contember/graphql-builder';
import { GraphQlFragment } from '@contember/graphql-builder';
import { GraphQlSelectionSet } from '@contember/graphql-builder';
import { Input } from '@contember/schema';
import { JSONObject } from '@contember/schema';
Expand Down Expand Up @@ -391,6 +392,9 @@ export type MutationError = {
readonly type: Result.ExecutionErrorType;
};

// @public (undocumented)
export const mutationFragments: Record<string, GraphQlFragment>;

// @public (undocumented)
export type MutationResult<Value = unknown> = {
readonly ok: boolean;
Expand Down
37 changes: 0 additions & 37 deletions build/api/client-generator.api.md

This file was deleted.

2 changes: 1 addition & 1 deletion build/api/interface-tester.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export const createEnvironment: ({ model, role, pageConfig }: {
role: string;
model: Model.Schema;
pageConfig: PageConfig;
}) => Environment;
}) => Environment<Environment.AnyNode | undefined>;

// @public (undocumented)
export const createNode: (value: any) => ReactNode[];
Expand Down
98 changes: 98 additions & 0 deletions build/api/interface.api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
## API Report File for "@contember/interface"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts

import { ContemberClientProps } from '@contember/react-client';
import { EntityAccessor } from '@contember/react-binding';
import { Environment } from '@contember/react-binding';
import { ErrorPersistResult } from '@contember/react-binding';
import { JSX as JSX_2 } from 'react/jsx-runtime';
import { NamedExoticComponent } from 'react';
import { ReactElement } from 'react';
import { ReactNode } from 'react';
import { RouteMap } from '@contember/react-routing';
import { RoutingLinkTarget } from '@contember/react-routing';
import { SuccessfulPersistResult } from '@contember/react-binding';
import { SugaredRelativeSingleField } from '@contember/react-binding';

// @public (undocumented)
export const ApplicationEntrypoint: (props: ApplicationEntrypointProps) => JSX_2.Element;

// @public (undocumented)
export interface ApplicationEntrypointProps extends ContemberClientProps {
// (undocumented)
basePath: string;
// (undocumented)
children: ReactNode;
// (undocumented)
environment?: Environment;
// (undocumented)
routes?: RouteMap;
// (undocumented)
sessionToken?: string;
}

// @public (undocumented)
export const ClearFieldTrigger: NamedExoticComponent<ClearFieldTriggerProps>;

// @public (undocumented)
export interface ClearFieldTriggerProps {
// (undocumented)
children: ReactNode;
// (undocumented)
field: SugaredRelativeSingleField['field'];
}

// @public (undocumented)
export const DeleteEntityTrigger: ({ immediatePersist, onPersistError, onPersistSuccess, ...props }: DeleteEntityTriggerProps) => JSX_2.Element;

// @public (undocumented)
export interface DeleteEntityTriggerProps {
// (undocumented)
children: ReactNode;
// (undocumented)
immediatePersist?: true;
// (undocumented)
onPersistError?: (result: ErrorPersistResult) => void;
// (undocumented)
onPersistSuccess?: (result: SuccessfulPersistResult) => void;
}

// @public (undocumented)
export const EntityBeforePersist: ({ listener }: {
listener: EntityAccessor.EntityEventListenerMap['beforePersist'];
}) => null;

// @public (undocumented)
export const PersistTrigger: ({ onPersistError, onPersistSuccess, ...props }: PersistTriggerProps) => JSX_2.Element;

// @public (undocumented)
export interface PersistTriggerProps {
// (undocumented)
children: ReactElement;
// (undocumented)
onPersistError?: (result: ErrorPersistResult) => void;
// (undocumented)
onPersistSuccess?: (result: SuccessfulPersistResult) => void;
}

// @public (undocumented)
export const RedirectOnPersist: ({ to }: {
to: RoutingLinkTarget;
}) => null;

// @public (undocumented)
export const runReactApp: (reactElement: ReactElement, { domRoot }?: {
domRoot?: HTMLElement | undefined;
}) => void;


export * from "@contember/react-binding";
export * from "@contember/react-identity";
export * from "@contember/react-routing";

// (No @packageDocumentation comment for this package)

```
4 changes: 2 additions & 2 deletions build/api/layout.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,8 @@ declare namespace Directives {
Directive,
ProviderProps,
Provider,
useDirectives,
StateContext,
useDirectives,
RegistryContext,
useRegistryContext,
RegistryContextType
Expand Down Expand Up @@ -852,7 +852,7 @@ export const useContainerInsetsContext: () => ContainerInsets;
function useDirectiveLifecycle<T extends Record<string, unknown>, K extends keyof T & string, V extends T[K]>(name: K, content: V): boolean;

// @public (undocumented)
function useDirectives<T extends Record<string, unknown>>(): T;
const useDirectives: <T extends Record<string, unknown>>() => T;

// @public (undocumented)
export function useElementInsetCustomProperties(elementRef: RefObject<HTMLElement>, prefix?: string): CSSProperties | undefined;
Expand Down
6 changes: 2 additions & 4 deletions build/api/react-auto.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,9 @@ export type AutoLabelProps = {
// @public (undocumented)
export interface InnerLinkProps {
// (undocumented)
active: boolean;
href?: string;
// (undocumented)
href: string;
// (undocumented)
onClick: (e?: MouseEvent_2<HTMLAnchorElement>) => void;
onClick?: (e?: MouseEvent_2<HTMLAnchorElement>) => void;
}

// @public (undocumented)
Expand Down
17 changes: 15 additions & 2 deletions build/api/react-binding.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import type { RelativeEntityList } from '@contember/binding';
import type { RelativeSingleEntity } from '@contember/binding';
import { RelativeSingleField } from '@contember/binding';
import type { SugaredParentEntityParameters } from '@contember/binding';
import type { SugaredQualifiedEntityList } from '@contember/binding';
import { SugaredQualifiedEntityList } from '@contember/binding';
import type { SugaredQualifiedSingleEntity } from '@contember/binding';
import type { SugaredRelativeEntityList } from '@contember/binding';
import type { SugaredRelativeSingleEntity } from '@contember/binding';
Expand Down Expand Up @@ -220,6 +220,9 @@ export interface EntityListSubTreeAdditionalProps {
variables?: Environment.ValuesMapWithFactory;
}

// @public (undocumented)
export type EntityListSubTreeLoaderState = 'initial' | 'refreshing' | 'loaded';

// @public (undocumented)
export type EntityListSubTreeProps<ListProps, EntityProps> = {
treeRootId?: TreeRootId;
Expand Down Expand Up @@ -278,7 +281,7 @@ export interface EnvironmentAwareFunctionComponent<P> {
}

// @public (undocumented)
export const EnvironmentContext: Context<Environment>;
export const EnvironmentContext: Context<Environment<Environment.AnyNode | undefined>>;

// @public (undocumented)
export interface EnvironmentDeltaProvider<Props extends {} = any> {
Expand Down Expand Up @@ -678,6 +681,16 @@ export function useEntityList(sugaredRelativeEntityList: string | SugaredRelativ
export const useEntityListSubTree: (qualifiedEntityList: Alias | SugaredQualifiedEntityList | SugaredUnconstrainedQualifiedEntityList, ...treeId: [TreeRootId | undefined] | [
]) => EntityListAccessor;

// @public (undocumented)
export const useEntityListSubTreeLoader: <State>(entities: SugaredQualifiedEntityList | undefined, children: ReactNode, state?: State | undefined) => [UseEntityListSubTreeLoaderResult<State>, EntityListSubTreeLoaderState];

// @public (undocumented)
export type UseEntityListSubTreeLoaderResult<State> = {
entities: SugaredQualifiedEntityList | undefined;
treeRootId: TreeRootId | undefined;
state: State | undefined;
};

// @public (undocumented)
export function useEntityListSubTreeParameters(alias: Alias): Alias;

Expand Down
Loading

0 comments on commit f395a54

Please sign in to comment.