Giter Site home page Giter Site logo

Comments (3)

puschie286 avatar puschie286 commented on May 27, 2024

check your html if the 'lm_close_tab' element exist - probably your image path is incorrect

from golden-layout.

danwellman avatar danwellman commented on May 27, 2024

Thanks, yes the lm_close_tab element does exist, but this is for the close icon next to the component name at the top-left of the header - this does display as expected and I can use it to close the components. But I am talking about the three controls at the top-right of the header.

In the HTML, the elements for these controls also exists - lm_popout, lm_maximise and lm_close and the images for these icons are base64 encoded strings, so there are no actual image paths to actual images.

The issue seems to be there there is no styling for these elements by default. I can fix it by supplying styling for the buttons and the controls container, but this seems strange given that no custom styling is needed for the close button at the top-left of each component.

Edit
Actually, the issue seems to be that the mark-up structure for these controls has changed in version 2. Previously these controls were built from a ul and li elements, but in version 2 they are made of div elements and hence do not pick up the required styles

from golden-layout.

RationalFragile avatar RationalFragile commented on May 27, 2024

Had the same issue, I copied the only example provided for v2 from https://codepen.io/pbklink/pen/dyWJNNm and the whole layout was broken...

I spent a whole day trying to make it work, then I found the solution: manually import "golden-layout/dist/css/goldenlayout-base.css" and "golden-layout/dist/css/themes/goldenlayout-dark-theme.css". Apparently, golden-layout doesn't import them automatically.

(facepalm, please add this to the v2 docs... or at least change the example to clearly show the required imports.)
(P.S. No, it doesn't matter whether they're "ul" or "li" or "div" they're styled by their class, check if you're referring to the latest css inside your "node_modules" folder.)

from golden-layout.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.