@@ -53,7 +53,7 @@ export class LayerPanel {
5353 const btnGroup = document . createElement ( "div" ) ;
5454 btnGroup . style . cssText = "display:flex;gap:4px" ;
5555
56- const addBtn = this . _makeBtn ( "+" , " Add layer ") ;
56+ const addBtn = this . _makeBtn ( "Add Layer " ) ;
5757 addBtn . addEventListener ( "click" , ( ) => {
5858 const active = this . layerManager . getActiveLayer ( ) ;
5959 const w = active ? active . renderTarget . width : 512 ;
@@ -72,14 +72,14 @@ export class LayerPanel {
7272 this . onLayerChange ( ) ;
7373 } ) ;
7474
75- const dupBtn = this . _makeBtn ( "D" , " Duplicate layer ") ;
75+ const dupBtn = this . _makeBtn ( "Duplicate" ) ;
7676 dupBtn . addEventListener ( "click" , ( ) => {
7777 this . layerManager . duplicateLayer ( this . layerManager . activeLayerIndex ) ;
7878 this . refresh ( ) ;
7979 this . onLayerChange ( ) ;
8080 } ) ;
8181
82- const delBtn = this . _makeBtn ( "-" , "Remove layer ") ;
82+ const delBtn = this . _makeBtn ( "Delete Layer " ) ;
8383 delBtn . addEventListener ( "click" , ( ) => {
8484 this . layerManager . removeLayer ( this . layerManager . activeLayerIndex ) ;
8585 this . refresh ( ) ;
@@ -526,11 +526,10 @@ export class LayerPanel {
526526 this . _renderer = renderer ;
527527 }
528528
529- _makeBtn ( text , title ) {
529+ _makeBtn ( text ) {
530530 const btn = document . createElement ( "button" ) ;
531531 btn . textContent = text ;
532- btn . title = title ;
533- btn . style . cssText = "width:24px;height:24px;border:1px solid #2a2a3a;border-radius:4px;background:#111122;color:#ccc;cursor:pointer;font-family:monospace;font-size:14px;display:flex;align-items:center;justify-content:center;transition:all 0.15s" ;
532+ btn . style . cssText = "padding:3px 8px;height:24px;border:1px solid #2a2a3a;border-radius:4px;background:#111122;color:#ccc;cursor:pointer;font-family:monospace;font-size:10px;display:flex;align-items:center;justify-content:center;transition:all 0.15s;white-space:nowrap" ;
534533 btn . addEventListener ( "mouseenter" , ( ) => { btn . style . background = "#1a1a3e" ; btn . style . borderColor = "#e94560" ; btn . style . color = "#fff" ; } ) ;
535534 btn . addEventListener ( "mouseleave" , ( ) => { btn . style . background = "#111122" ; btn . style . borderColor = "#2a2a3a" ; btn . style . color = "#ccc" ; } ) ;
536535 return btn ;
0 commit comments