Skip to content

Commit

Permalink
Finish UI
Browse files Browse the repository at this point in the history
  • Loading branch information
HardeepAsrani committed Dec 25, 2023
1 parent e3f93ab commit 619dcc7
Show file tree
Hide file tree
Showing 11 changed files with 404 additions and 40 deletions.
128 changes: 100 additions & 28 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
"pre-commit": "npm run lint:js && composer run-script lint && composer run-script phpstan"
},
"dependencies": {
"@wordpress/icons": "^9.39.0",
"classnames": "^2.3.2"
}
}
17 changes: 17 additions & 0 deletions src/components/TemplatePreview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* WordPress dependencies.
*/
import { BlockPreview } from '@wordpress/block-editor';

const TemplatePreview = ({ template }) => {
return (
<div className="block basis-full rounded-xl overflow-hidden max-h-80vh">
<BlockPreview
blocks={ template }
viewportWidth={ 1400 }
/>
</div>
);
};

export default TemplatePreview;
Loading

0 comments on commit 619dcc7

Please sign in to comment.