Updates to rendering

This commit is contained in:
Sean Edmunds
2026-02-02 11:40:42 -06:00
parent efffa3acbf
commit 5cc3b8bf6a
6 changed files with 244 additions and 267 deletions

View File

@@ -43,22 +43,24 @@ export function ThemeCard({
pos={'relative'}
ref={hoverRef}
>
<DeleteItemModal
modalOpened={modalOpened}
handleClose={closeModal}
handleDelete={() => handleDelete(cardTheme, 'api/themes')}
title={'Delete Theme'}
body={
<Stack gap={0} w={'100%'} h={'150px'} align='center'>
<Text>Are you sure you want to delete this theme?</Text>
<Text
className={textClasses.deleteItem}
classNames={textClasses}
>{`"${cardTheme.name}"`}</Text>
<Text c='red'>This action cannot be undone!</Text>
</Stack>
}
/>
{modalOpened && (
<DeleteItemModal
modalOpened={modalOpened}
handleClose={closeModal}
handleDelete={() => handleDelete(cardTheme, 'api/themes')}
title={'Delete Theme'}
body={
<Stack gap={0} w={'100%'} h={'150px'} align='center'>
<Text>Are you sure you want to delete this theme?</Text>
<Text
className={textClasses.deleteItem}
classNames={textClasses}
>{`"${cardTheme.name}"`}</Text>
<Text c='red'>This action cannot be undone!</Text>
</Stack>
}
/>
)}
<Text
style={{
position: 'absolute',

View File

@@ -98,25 +98,30 @@ export function Themes() {
setIsLoading(false);
}
}, [debouncedSearch]);
return (
<Stack>
<ThemeModal
opened={themeModalOpened}
selectedTheme={selectedTheme}
setSelectedTheme={setSelectedTheme}
backgroundList={backgroundList}
isNew={isNew}
setIsNew={setIsNew}
allThemes={allThemes}
closeThemeModal={closeThemeModal}
themePlaylists={themePlaylists}
/>
<BackgroundModal
backgroundModalOpened={backgroundModalOpened}
closeModal={closeBackgroundModal}
backgroundList={backgroundList}
inUseBackgrounds={inUseBackgrounds}
/>
{themeModalOpened && (
<ThemeModal
opened={themeModalOpened}
selectedTheme={selectedTheme}
setSelectedTheme={setSelectedTheme}
backgroundList={backgroundList}
isNew={isNew}
setIsNew={setIsNew}
allThemes={allThemes}
closeThemeModal={closeThemeModal}
themePlaylists={themePlaylists}
/>
)}
{backgroundModalOpened && (
<BackgroundModal
backgroundModalOpened={backgroundModalOpened}
closeModal={closeBackgroundModal}
backgroundList={backgroundList}
inUseBackgrounds={inUseBackgrounds}
/>
)}
<SettingsHeader
setDragging={undefined}
openModal={handleNewTheme}