diff options
author | a-kenji <aks.kenji@protonmail.com> | 2021-08-26 15:06:59 +0200 |
---|---|---|
committer | a-kenji <aks.kenji@protonmail.com> | 2021-08-26 15:06:59 +0200 |
commit | cd0b0119a022926e659d941f3013b618164e6881 (patch) | |
tree | 10575129e6ff3c9da604f8fe622511cbb9987a43 /zellij-client/src | |
parent | 06e3be6205bdde46b01f21d95180fcb641e42816 (diff) |
Split tab-layout into `template` & `tabs` section
* adjust example layouts and move them from `./example` to
`./example/layouts`
* simplify the deserialization of the layout
* layouts are now constructed as follows:
```
---
template:
direction: Horizontal
parts:
- direction: Vertical
borderless: true
split_size:
Fixed: 1
run:
plugin: tab-bar
- direction: Vertical
body: true # <== The body section specifies the position of the
# inserted tab
- direction: Vertical
borderless: true
split_size:
Fixed: 2
run:
plugin: status-bar
tabs:
- direction: Vertical
- direction: Vertical
```
Diffstat (limited to 'zellij-client/src')
-rw-r--r-- | zellij-client/src/lib.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/zellij-client/src/lib.rs b/zellij-client/src/lib.rs index f74a74ddf..e806ec3bf 100644 --- a/zellij-client/src/lib.rs +++ b/zellij-client/src/lib.rs @@ -14,14 +14,14 @@ use crate::{ command_is_executing::CommandIsExecuting, input_handler::input_loop, os_input_output::ClientOsApi, }; -use zellij_utils::cli::CliArgs; use zellij_utils::{ channels::{self, ChannelWithContext, SenderWithContext}, consts::{SESSION_NAME, ZELLIJ_IPC_PIPE}, errors::{ClientContext, ContextType, ErrorInstruction}, - input::{actions::Action, config::Config, layout::LayoutTemplate, options::Options}, + input::{actions::Action, config::Config, options::Options}, ipc::{ClientAttributes, ClientToServerMsg, ExitReason, ServerToClientMsg}, }; +use zellij_utils::{cli::CliArgs, input::layout::LayoutFromYaml}; /// Instructions related to the client-side application #[derive(Debug, Clone)] @@ -87,7 +87,7 @@ pub fn start_client( opts: CliArgs, config: Config, info: ClientInfo, - layout: Option<LayoutTemplate>, + layout: Option<LayoutFromYaml>, ) { info!("Starting Zellij client!"); let clear_client_terminal_attributes = "\u{1b}[?1l\u{1b}=\u{1b}[r\u{1b}12l\u{1b}[?1000l\u{1b}[?1002l\u{1b}[?1003l\u{1b}[?1005l\u{1b}[?1006l\u{1b}[?12l"; |