diff --git a/.gitignore b/.gitignore
index 74438716..4a3bc0c8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,7 +2,8 @@
node_modules/
.sass-cache/
build/**
-assets/
+# Only ignore root-level assets directory (build output), not module assets (source files)
+/assets/
hello-elementor/
elementor-hello-theme/
log/
@@ -13,7 +14,6 @@ Thumbs.db
*.log
*.map
yarn.lock
-assets/js/
*.zip
.npmrc
.env
diff --git a/modules/admin-home/assets/images/plus.svg b/modules/admin-home/assets/images/plus.svg
new file mode 100644
index 00000000..ceedebe3
--- /dev/null
+++ b/modules/admin-home/assets/images/plus.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/modules/admin-home/assets/js/components/settings/changelog.js b/modules/admin-home/assets/js/components/settings/changelog.js
new file mode 100644
index 00000000..72e824f8
--- /dev/null
+++ b/modules/admin-home/assets/js/components/settings/changelog.js
@@ -0,0 +1,44 @@
+import Dialog from '@elementor/ui/Dialog';
+import DialogContent from '@elementor/ui/DialogContent';
+import DialogHeader from '@elementor/ui/DialogHeader';
+import Typography from '@elementor/ui/Typography';
+import { __ } from '@wordpress/i18n';
+import Stack from '@elementor/ui/Stack';
+import Update from './update';
+import Divider from '@elementor/ui/Divider';
+import { PlusIcon } from './plus-icon';
+import { Fragment } from 'react';
+
+export const ChangelogDialog = ( { open, onClose, whatsNew } ) => {
+ return (
+
+ );
+};
diff --git a/modules/admin-home/assets/js/components/settings/plus-icon.js b/modules/admin-home/assets/js/components/settings/plus-icon.js
new file mode 100644
index 00000000..5d1c8685
--- /dev/null
+++ b/modules/admin-home/assets/js/components/settings/plus-icon.js
@@ -0,0 +1,10 @@
+import SvgIcon from '@elementor/ui/SvgIcon';
+import { ReactComponent as Icon } from '../../../images/plus.svg';
+
+export const PlusIcon = ( props ) => {
+ return (
+
+
+
+ );
+};
diff --git a/modules/admin-home/assets/js/components/settings/settings-page.js b/modules/admin-home/assets/js/components/settings/settings-page.js
index 57d99422..7c5f1282 100644
--- a/modules/admin-home/assets/js/components/settings/settings-page.js
+++ b/modules/admin-home/assets/js/components/settings/settings-page.js
@@ -18,8 +18,7 @@ import Paper from '@elementor/ui/Paper';
import { styled } from '@elementor/ui/styles';
import Link from '@elementor/ui/Link';
import Stack from '@elementor/ui/Stack';
-import Modal from '@elementor/ui/Modal';
-import Update from './update';
+import { ChangelogDialog } from './changelog';
const Notices = () => {
const notices = useSelect(
@@ -75,19 +74,6 @@ const StyledTabs = styled( Tabs )( () => ( {
},
} ) );
-const style = {
- position: 'absolute',
- top: '50%',
- left: '50%',
- transform: 'translate(-50%, -50%)',
- bgcolor: 'background.paper',
- border: '1px solid #000',
- boxShadow: 24,
- p: 2,
- maxHeight: '80vh',
- overflowY: 'auto',
-};
-
export const SettingsPage = () => {
const { whatsNew } = useSettingsContext();
const { getTabsProps, getTabProps, getTabPanelProps } = useTabs( 'one' );
@@ -131,19 +117,7 @@ export const SettingsPage = () => {
-
-
- { __( 'Changelog', 'hello-plus' ) }
-
- { whatsNew.map( ( item ) => ) }
-
-
-
+
>
);
};
diff --git a/modules/admin-home/assets/js/components/settings/update.js b/modules/admin-home/assets/js/components/settings/update.js
index 06baf9f2..143dcc49 100644
--- a/modules/admin-home/assets/js/components/settings/update.js
+++ b/modules/admin-home/assets/js/components/settings/update.js
@@ -1,11 +1,19 @@
-import Stack from '@elementor/ui/Stack';
+import Box from '@elementor/ui/Box';
import Typography from '@elementor/ui/Typography';
+import { useMemo } from 'react';
export default function Update( { title, description } ) {
+ const descriptionToShow = useMemo( () => {
+ const parser = new DOMParser();
+ const doc = parser.parseFromString( description, 'text/html' );
+ const listItems = doc.querySelectorAll( 'li' );
+ const extractedContent = Array.from( listItems ).map( ( item ) => item.textContent.trim() );
+ return extractedContent.join( '\n' );
+ }, [ description ] );
return (
-
- { title }
-
-
+
+ { title }
+ { descriptionToShow }
+
);
}