diff --git a/gui/dom/package.json b/gui/dom/package.json index 4864ade0b..37a9f47ad 100644 --- a/gui/dom/package.json +++ b/gui/dom/package.json @@ -1,6 +1,6 @@ { "name": "taipy-gui-dom", - "version": "2.2.0", + "version": "2.2.1", "private": true, "dependencies": { "react": "^18.2.0", diff --git a/gui/package.json b/gui/package.json index 79d84c7fa..68845fb6c 100644 --- a/gui/package.json +++ b/gui/package.json @@ -1,6 +1,6 @@ { "name": "taipy-gui", - "version": "2.2.0", + "version": "2.2.1", "private": true, "dependencies": { "@emotion/react": "^11.10.0", diff --git a/gui/packaging/package.json b/gui/packaging/package.json index 9b85bd743..f6e200f94 100644 --- a/gui/packaging/package.json +++ b/gui/packaging/package.json @@ -1,6 +1,6 @@ { "name": "taipy-gui", - "version": "2.2.0", + "version": "2.2.1", "private": true, "main": "./taipy-gui.js", "types": "./taipy-gui.d.ts" diff --git a/gui/src/components/Taipy/Part.tsx b/gui/src/components/Taipy/Part.tsx index 3e08c1205..90d560a8f 100644 --- a/gui/src/components/Taipy/Part.tsx +++ b/gui/src/components/Taipy/Part.tsx @@ -25,18 +25,19 @@ interface PartProps extends TaipyBaseProps { page?: string; defaultPage?: string; children?: ReactNode; + defaultPartial?: boolean; partial?: boolean; } const Part = (props: PartProps) => { - const { id, children, partial } = props; + const { id, children, partial, defaultPartial } = props; const { state } = useContext(TaipyContext); const className = useClassNames(props.libClassName, props.dynamicClassName, props.className); const render = useDynamicProperty(props.render, props.defaultRender, true); const page = useDynamicProperty(props.page, props.defaultPage, ""); const iFrame = useMemo(() => { - if (page && !partial) { + if (page && !defaultPartial) { if (/^https?\:\/\//.test(page)) { return true; } @@ -44,7 +45,7 @@ const Part = (props: PartProps) => { return !Object.keys(state.locations || {}).some((route) => sPage === route); } return false; - }, [state.locations, page, partial]); + }, [state.locations, page, defaultPartial]); return render ? ( diff --git a/src/taipy/gui/renderers/builder.py b/src/taipy/gui/renderers/builder.py index e644a3d30..c902ee674 100644 --- a/src/taipy/gui/renderers/builder.py +++ b/src/taipy/gui/renderers/builder.py @@ -732,6 +732,7 @@ def _set_partial(self): if isinstance(partial, Partial): self.__attributes["page"] = partial._route self.__set_react_attribute("partial", partial._route) + self.__set_react_attribute("defaultPartial", True) return self def _set_propagate(self): diff --git a/src/taipy/gui/version.json b/src/taipy/gui/version.json index caaf4742d..2199e399b 100644 --- a/src/taipy/gui/version.json +++ b/src/taipy/gui/version.json @@ -1 +1 @@ -{"major": 2, "minor": 2, "patch": 0, "ext": ""} +{"major": 2, "minor": 2, "patch": 1, "ext": ""}