From 952aa63147c9fb28f6ace6f0bc7ccf45ced1299a Mon Sep 17 00:00:00 2001 From: Kiran George Date: Mon, 9 Jun 2025 11:30:08 +0530 Subject: Overview v2 --- config/quickshell/modules/common/functions/file_utils.js | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 config/quickshell/modules/common/functions/file_utils.js (limited to 'config/quickshell/modules/common/functions/file_utils.js') diff --git a/config/quickshell/modules/common/functions/file_utils.js b/config/quickshell/modules/common/functions/file_utils.js new file mode 100644 index 00000000..758950de --- /dev/null +++ b/config/quickshell/modules/common/functions/file_utils.js @@ -0,0 +1,9 @@ +/** + * Trims the File protocol off the input string + * @param {string} str + * @returns {string} + */ +function trimFileProtocol(str) { + return str.startsWith("file://") ? str.slice(7) : str; +} + -- cgit v1.2.3