Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 30 additions & 3 deletions modules/i3/hm.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,35 @@ let
};
in
{
options.stylix.targets.i3.enable = config.lib.stylix.mkEnableTarget "i3" true;
imports = [
(
{ config, ... }:
{
lib.stylix.i3.bar = builtins.warn "stylix: `config.lib.stylix.i3.bar` has been renamed to `config.stylix.targets.i3.exportedBarConfig` and will be removed after 26.11." config.stylix.targets.i3.exportedBarConfig;
}
)
];
options.stylix.targets.i3 = {
enable = config.lib.stylix.mkEnableTarget "i3" true;
exportedBarConfig = lib.mkOption {
type = lib.types.attrs;
description = ''
Theming configuration which can be merged with your own:

```nix
Comment thread
Flameopathic marked this conversation as resolved.
xsession.windowManager.i3.config.bars = [
(
{
# your configuration
}
// config.stylix.targets.i3.exportedBarConfig
)
];
```
'';
readOnly = true;
};
};

config =
with config.lib.stylix.colors.withHashtag;
Expand Down Expand Up @@ -64,8 +92,7 @@ in
})

{
# Merge this with your bar configuration using //config.lib.stylix.i3.bar
lib.stylix.i3.bar = {
stylix.targets.i3.exportedBarConfig = {
inherit fonts;

colors =
Expand Down
7 changes: 7 additions & 0 deletions modules/i3/meta.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,11 @@
name = "i3";
homepage = "https://i3wm.org/";
maintainers = [ ];
description = ''
> [!IMPORTANT]
>
> The `config.xsession.windowManager.i3.config.bars` option is not themed.
> Use the [`config.stylix.targets.i3.exportedBarConfig`](
> #stylixtargetsswayexportedbarconfig) option to customize it.
'';
}
29 changes: 27 additions & 2 deletions modules/sway/hm.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,35 @@ let
};
in
{
imports = [
(
{ config, ... }:
{
lib.stylix.sway.bar = builtins.warn "stylix: `config.lib.stylix.sway.bar` has been renamed to `config.stylix.targets.sway.exportedBarConfig` and will be removed after 26.11." config.stylix.targets.sway.exportedBarConfig;
}
)
];
options.stylix.targets.sway = {
enable = config.lib.stylix.mkEnableTarget "Sway" true;
useWallpaper = config.lib.stylix.mkEnableWallpaper "Sway" true;
exportedBarConfig = lib.mkOption {
type = lib.types.attrs;
description = ''
Theming configuration which can be merged with your own:

```nix
Comment thread
Flameopathic marked this conversation as resolved.
wayland.windowManager.sway.config.bars = [
(
{
# your configuration
}
// config.stylix.targets.sway.exportedBarConfig
)
];
```
'';
readOnly = true;
};
};

config =
Expand Down Expand Up @@ -69,8 +95,7 @@ in
})

{
# Merge this with your bar configuration using //config.lib.stylix.sway.bar
lib.stylix.sway.bar = {
stylix.targets.sway.exportedBarConfig = {
inherit fonts;

colors =
Expand Down
7 changes: 7 additions & 0 deletions modules/sway/meta.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,11 @@
name = "Sway";
homepage = "https://swaywm.org/";
maintainers = [ ];
description = ''
> [!IMPORTANT]
>
> The `config.wayland.windowManager.sway.config.bars` option is not themed.
> Use the [`config.stylix.targets.sway.exportedBarConfig`](
> #stylixtargetsswayexportedbarconfig) option to customize it.
'';
}