diff options
| author | Aram Drevekenin <aram@poor.dev> | 2024-03-26 16:37:42 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-26 16:37:42 +0100 |
| commit | 631ffd9bc46e9b4f79794525793e0cd2b76a10fa (patch) | |
| tree | 831e987e3dfbc28a3097f5b5ebae93ef64ab67f1 /default-plugins/session-manager/src/main.rs | |
| parent | docs(changelog): binding ctrl space (diff) | |
| download | sl0ppij-631ffd9bc46e9b4f79794525793e0cd2b76a10fa.tar.gz sl0ppij-631ffd9bc46e9b4f79794525793e0cd2b76a10fa.tar.xz sl0ppij-631ffd9bc46e9b4f79794525793e0cd2b76a10fa.zip | |
fix(ui): session manager UI fixes (#3226)
* fix(ui): display new session folder prompt always
* fix(ui): truncate session name and error on too long a name
* fix(ui): scrolling layout list in welcome screen
* style(fmt): rustfmt
Diffstat (limited to 'default-plugins/session-manager/src/main.rs')
| -rw-r--r-- | default-plugins/session-manager/src/main.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/default-plugins/session-manager/src/main.rs b/default-plugins/session-manager/src/main.rs index 7015144f..9f37a34a 100644 --- a/default-plugins/session-manager/src/main.rs +++ b/default-plugins/session-manager/src/main.rs @@ -383,6 +383,14 @@ impl State { fn handle_selection(&mut self) { match self.active_screen { ActiveScreen::NewSession => { + if self.new_session_info.name().len() >= 108 { + // this is due to socket path limitations + // TODO: get this from Zellij (for reference: this is part of the interprocess + // package, we should get if from there if possible because it's configurable + // through the package) + self.show_error("Session name must be shorter than 108 bytes"); + return; + } self.new_session_info.handle_selection(&self.session_name); }, ActiveScreen::AttachToSession => { |
