[GH-ISSUE #655] Add home-manager option to import a style.css file #3032

Closed
opened 2026-05-22 23:53:33 +01:00 by JakeStanger · 0 comments
Owner

Originally created by @Alpha-Ursae-Minoris on GitHub (Jul 1, 2024).
Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/655

Is your feature request related to a problem? Please describe.

Currently programs.ironbar.style = only accepts nix strings concatenated with \n, this is caused by only allowing the type lib.types.lines in the option definition:

style = lib.mkOption {
              type = lib.types.lines;
              default = "";
              description = "The stylesheet to apply to ironbar.";
            };

Describe the solution you'd like

Add the option to import the css styling from a style.css file, by adding the option to import via a path. This would mirror the implementation used for the waybar.style option:

    style = mkOption {
      type = nullOr (either path lines);
      default = null;
      description = ''
        CSS style of the bar.

        See <https://github.com/Alexays/Waybar/wiki/Configuration>
        for the documentation.

        If the value is set to a path literal, then the path will be used as the css file.
      '';
      example = ''
        * {
          border: none;
          border-radius: 0;
          font-family: Source Code Pro;
        }
        window#waybar {
          background: #16191C;
          color: #AAB2BF;
        }
        #workspaces button {
          padding: 0 5px;
        }
      '';
    };

Describe alternatives you've considered

N/A

Additional context

None

Originally created by @Alpha-Ursae-Minoris on GitHub (Jul 1, 2024). Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/655 **Is your feature request related to a problem? Please describe.** Currently `programs.ironbar.style =` only accepts nix strings concatenated with \n, this is caused by only allowing the type `lib.types.lines` in the option definition: ```nix style = lib.mkOption { type = lib.types.lines; default = ""; description = "The stylesheet to apply to ironbar."; }; ``` **Describe the solution you'd like** Add the option to import the css styling from a style.css file, by adding the option to import via a path. This would mirror the implementation used for the `waybar.style` option: ```nix style = mkOption { type = nullOr (either path lines); default = null; description = '' CSS style of the bar. See <https://github.com/Alexays/Waybar/wiki/Configuration> for the documentation. If the value is set to a path literal, then the path will be used as the css file. ''; example = '' * { border: none; border-radius: 0; font-family: Source Code Pro; } window#waybar { background: #16191C; color: #AAB2BF; } #workspaces button { padding: 0 5px; } ''; }; ``` **Describe alternatives you've considered** > N/A **Additional context** > None
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
JakeStanger/ironbar#3032
No description provided.