@@ -291,17 +291,10 @@ class CssSnippetStoreModal extends Modal {
291
291
placeholder : 'Search snippets...' ,
292
292
} ) ;
293
293
searchInput . classList . add ( 'snippet-search-input' ) ;
294
- searchInput . style . marginBottom = '1rem' ;
295
- searchInput . style . width = '100%' ;
296
- searchInput . style . padding = '0.5rem' ;
297
294
298
295
// Message container
299
296
const messageEl = topContainer . createEl ( 'div' ) ;
300
297
messageEl . classList . add ( 'snippet-status-message' ) ;
301
- messageEl . style . marginTop = '0.5rem' ;
302
- messageEl . style . textAlign = 'center' ;
303
- messageEl . style . color = 'var(--text-muted)' ;
304
- messageEl . style . fontStyle = 'italic' ;
305
298
306
299
// Snippet container
307
300
contentEl . createEl ( 'div' , { cls : 'community-items-container' } ) ;
@@ -365,8 +358,7 @@ class SnippetReadmeModal extends Modal {
365
358
const { contentEl } = this ;
366
359
contentEl . empty ( ) ;
367
360
contentEl . addClass ( "snippet-readme-modal" ) ;
368
- this . modalEl . style . width = "80vw" ;
369
- this . modalEl . style . height = "80vh" ;
361
+ this . modalEl . addClass ( "snippet-readme-modal-element" ) ;
370
362
371
363
// Show loading indicator if no content yet
372
364
if ( ! this . readmeContent ) {
@@ -405,10 +397,7 @@ class SnippetReadmeModal extends Modal {
405
397
// Optimize image loading
406
398
markdownContainer . querySelectorAll ( "img" ) . forEach ( ( img ) => {
407
399
img . setAttribute ( "loading" , "lazy" ) ;
408
- img . style . maxWidth = "100%" ;
409
- img . style . height = "auto" ;
410
- img . style . display = "block" ;
411
- img . style . margin = "1rem auto" ;
400
+ img . addClass ( "snippet-readme-image" ) ;
412
401
} ) ;
413
402
} catch ( error ) {
414
403
console . error ( "Error rendering README:" , error ) ;
0 commit comments