Skip to content

Commit

Permalink
Page Builder API for extension library elements... and a bit more (#2438
Browse files Browse the repository at this point in the history
)

- Added taipy.gui.extention entry point for API generation.
- Code reorganization.
- Hide inner properties.
- Store extension libraries element constructors in their library module.
- Added PropertyType.any and dynamic_any.
- Added optional documentation on extension library elements and their properties.
- Added test on tgb api generation for extension libraries.
  • Loading branch information
FabienLelaquais authored Feb 7, 2025
1 parent 749373f commit a932f8c
Show file tree
Hide file tree
Showing 11 changed files with 657 additions and 374 deletions.
8 changes: 4 additions & 4 deletions frontend/taipy-gui/src/components/Taipy/tableUtils.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,6 @@ import { FormatConfig } from "../../context/taipyReducers";
import { dateToString, getDateTime, getDateTimeString, getNumberString, getTimeZonedDate } from "../../utils/index";
import { TaipyActiveProps, TaipyMultiSelectProps, getSuffixedClassNames } from "./utils";

/**
* A column description as received by the backend.
*/

/**
* Generates a CSS class name for a table header.
* @param columnName - The name of the column.
Expand All @@ -63,6 +59,10 @@ export const generateHeaderClassName = (columnName: string | undefined): string
return "-" + columnName.replace(/\W+/g, "-").replace(/-+/g, "-").toLowerCase();
};

/**
* A column description as received by the backend.
*/

export interface ColumnDesc {
/** The unique column identifier. */
dfid: string;
Expand Down
36 changes: 18 additions & 18 deletions frontend/taipy-gui/src/components/Taipy/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,29 +14,33 @@
import { MouseEvent, ReactNode } from "react";
import { SxProps } from "@mui/material";

export interface TaipyActiveProps extends TaipyDynamicProps, TaipyHoverProps {
defaultActive?: boolean;
active?: boolean;
export interface TaipyBaseProps {
id?: string;
libClassName?: string;
className?: string;
dynamicClassName?: string;
privateClassName?: string;
children?: ReactNode;
}

interface TaipyDynamicProps extends TaipyBaseProps {
updateVarName?: string;
propagate?: boolean;
updateVars?: string;
}

export interface TaipyHoverProps {
hoverText?: string;
defaultHoverText?: string;
}

interface TaipyDynamicProps extends TaipyBaseProps {
updateVarName?: string;
propagate?: boolean;
updateVars?: string;
export interface TaipyActiveProps extends TaipyDynamicProps, TaipyHoverProps {
defaultActive?: boolean;
active?: boolean;
}

export interface TaipyBaseProps {
id?: string;
libClassName?: string;
className?: string;
dynamicClassName?: string;
privateClassName?: string;
children?: ReactNode;
export interface TaipyLabelProps {
label?: string;
}

export interface TaipyMultiSelectProps {
Expand Down Expand Up @@ -68,10 +72,6 @@ export interface TaipyInputProps extends TaipyActiveProps, TaipyChangeProps, Tai
width?: string | number;
}

export interface TaipyLabelProps {
label?: string;
}

export interface DateProps {
maxDate?: unknown;
maxDateTime?: unknown;
Expand Down
Loading

0 comments on commit a932f8c

Please sign in to comment.