Server IP : 13.213.54.232 / Your IP : 216.73.217.11 Web Server : Apache/2.4.52 (Ubuntu) System : Linux ip-172-31-17-110 6.8.0-1029-aws #31~22.04.1-Ubuntu SMP Thu Apr 24 21:16:18 UTC 2025 x86_64 User : www-data ( 33) PHP Version : 7.1.33-67+ubuntu22.04.1+deb.sury.org+1 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /proc/thread-self/root/snap/lxd/current/share/lxd-ui/assets/ |
Upload File : |
import{j as s,aa as h,d as l}from"./index-13b2882d.js";import{S as o}from"./updateMaxHeight-325b3cd4.js";const j=({name:a,titleClassName:r,parentItems:u,centerControls:d,controls:m,isLoaded:i,formik:e,renameDisabledReason:t})=>{const c=t===void 0,p=()=>{c&&e.setValues({...e.values,isRenaming:!0})};return s.jsxs("div",{className:"p-panel__header rename-header",children:[s.jsx("h1",{className:"u-off-screen",children:a}),i?s.jsxs("div",{className:h("p-panel__title",r),children:[s.jsx("nav",{className:"p-breadcrumbs","aria-label":"Breadcrumbs",children:s.jsxs("ol",{className:"p-breadcrumbs__items",children:[u.map((n,b)=>s.jsx("li",{className:"p-breadcrumbs__item",children:n},b)),e.values.isRenaming?s.jsxs("li",{className:"p-breadcrumbs__item rename",children:[s.jsx(l.Input,{autoFocus:!0,id:"name",name:"name",className:"name-input",onBlur:e.handleBlur,onChange:e.handleChange,value:e.values.name,error:e.touched.name?e.errors.name:null,onKeyUp:n=>n.key==="Enter"&&void e.submitForm(),type:"text"}),s.jsxs("div",{children:[s.jsx(l.Button,{appearance:"base",className:"cancel",onClick:()=>void e.setFieldValue("isRenaming",!1),children:"Cancel"}),s.jsx(o,{isSubmitting:e.isSubmitting,isDisabled:!e.isValid||a===e.values.name,buttonLabel:"Save",onClick:()=>void e.submitForm()})]})]}):s.jsx("li",{className:"p-breadcrumbs__item name u-truncate",onClick:p,title:a,children:s.jsx(l.Tooltip,{message:!c&&t,position:"btm-left",children:a})})]})},"breadcrumbs"),!e.values.isRenaming&&d]}):s.jsx("h4",{className:"p-panel__title",children:a}),i&&!e.values.isRenaming&&s.jsx("div",{className:"p-panel__controls",children:m})]})};export{j as R};