PageSourceSearch

https://kiku.listen.org/2734.7225105fb824d719.bundle.js

js listen.org collected 2026-10-02 06:40:55 UTC 17,527 bytes, 1 lines download raw bytes

1"use strict";(self["webpackChunkclient"]=self["webpackChunkclient"]||[]).push([[2734],{1068:function(e,t,l){l.d(t,{A:function(){return m}});var a=l(20641),o=l(90033);const s={key:0},i={key:1},r={key:2};function n(e,t,l,n,u,c){const d=(0,a.g2)("b-button"),m=(0,a.g2)("b-dropdown-item"),p=(0,a.g2)("b-dropdown");return(0,a.uX)(),(0,a.Wv)(p,{"aria-role":"list",position:l.position,scrollable:"","max-height":"250",expanded:l.expanded,"append-to-body":l.appendToBody,class:"color-picker-dropdown"},{trigger:(0,a.k6)(()=>[(0,a.bF)(d,{label:l.buttonLabel||e.$t(c.getColorLabel(l.modelValue)),style:(0,o.Tr)(c.getButtonStyle()),expanded:l.expanded,type:l.buttonType,size:l.buttonSize},{default:(0,a.k6)(()=>[l.buttonLabel?((0,a.uX)(),(0,a.CE)("span",s,(0,o.v_)(l.buttonLabel),1)):l.modelValue?((0,a.uX)(),(0,a.CE)("span",i,[(0,a.Lk)("span",{class:"color-preview mr-2",style:(0,o.Tr)(c.getPreviewStyle())},null,4),(0,a.eW)(" "+(0,o.v_)(e.$t(c.getColorLabel(l.modelValue))),1)])):((0,a.uX)(),(0,a.CE)("span",r,(0,o.v_)(e.$t("Default")),1))]),_:1},8,["label","style","expanded","type","size"])]),default:(0,a.k6)(()=>[(0,a.bF)(m,{"aria-role":"listitem",onClick:t[0]||(t[0]=e=>c.updateValue(""))},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Default")),1)]),_:1}),((0,a.uX)(!0),(0,a.CE)(a.FK,null,(0,a.pI)(c.tailwindColors,t=>((0,a.uX)(),(0,a.Wv)(m,{key:t.name,"aria-role":"listitem",style:(0,o.Tr)(c.getItemStyle(t.value)),onClick:e=>c.updateValue(t.value)},{default:(0,a.k6)(()=>[(0,a.Lk)("span",{class:"is-flex is-align-items-center",style:(0,o.Tr)({color:`var(--${t.value}-${"dark"===e.$store.state.theme?"200":"800"})`})},(0,o.v_)(e.$t(t.label)),5)]),_:2},1032,["style","onClick"]))),128))]),_:1},8,["position","expanded","append-to-body"])}l(18111),l(22489),l(20116);var u={name:"ColorPicker",props:{modelValue:{type:String,default:""},position:{type:String,default:"is-top-right"},expanded:{type:Boolean,default:!1},buttonType:{type:String,default:""},buttonSize:{type:String,default:""},includeColors:{type:Array,default:null},excludeColors:{type:Array,default:()=>[]},buttonLabel:{type:String,default:""},appendToBody:{type:Boolean,default:!1}},emits:["update:modelValue"],computed:{tailwindColors(){const e=[{name:"slate",label:"Slate",value:"slate"},{name:"zinc",label:"Zinc",value:"zinc"},{name:"red",label:"Red",value:"red"},{name:"orange",label:"Orange",value:"orange"},{name:"amber",label:"Amber",value:"amber"},{name:"yellow",label:"Yellow",value:"yellow"},{name:"lime",label:"Lime",value:"lime"},{name:"olive",label:"Olive",value:"olive"},{name:"green",label:"Green",value:"green"},{name:"emerald",label:"Emerald",value:"emerald"},{name:"baby-blue",label:"Baby Blue",value:"baby-blue"},{name:"cyan",label:"Cyan",value:"cyan"},{name:"sky",label:"Sky",value:"sky"},{name:"blue",label:"Blue",value:"blue"},{name:"teal",label:"Teal",value:"teal"},{name:"indigo",label:"Indigo",value:"indigo"},{name:"violet",label:"Violet",value:"violet"},{name:"purple",label:"Purple",value:"purple"},{name:"fuchsia",label:"Fuchsia",value:"fuchsia"},{name:"pink",label:"Pink",value:"pink"},{name:"rose",label:"Rose",value:"rose"}];let t=e;return this.includeColors&&this.includeColors.length>0&&(t=t.filter(e=>this.includeColors.includes(e.value))),this.excludeColors.length>0&&(t=t.filter(e=>!this.excludeColors.includes(e.value))),t}},methods:{getColorLabel(e){if(!e)return this.$t("Default");if(e.startsWith("#"))return"Custom";const t=this.tailwindColors.find(t=>t.value===e);return t?t.label:e},getButtonStyle(){if(!this.modelValue)return{};if(this.modelValue.startsWith("#"))return{backgroundColor:this.modelValue,color:"#ffffff",borderColor:this.modelValue};const e="dark"===this.$store.state.theme;return{backgroundColor:`var(--${this.modelValue}-${e?"800":"200"})`,color:`var(--${this.modelValue}-${e?"200":"800"})`,borderColor:`var(--${this.modelValue}-${e?"700":"300"})`}},getPreviewStyle(){if(!this.modelValue)return{};if(this.modelValue.startsWith("#"))return{backgroundColor:this.modelValue,width:"20px",height:"20px",borderRadius:"4px",display:"inline-block"};const e="dark"===this.$store.state.theme;return{backgroundColor:`var(--${this.modelValue}-${e?"200":"800"})`,width:"20px",height:"20px",borderRadius:"4px",display:"inline-block"}},getItemStyle(e){const t="dark"===this.$store.state.theme;return{backgroundColor:`var(--${e}-${t?"800":"200"})`,color:`var(--${e}-${t?"200":"800"})`}}
1,updateValue(e){this.$emit("update:modelValue",e)}}},c=l(66262);const d=(0,c.A)(u,[["render",n],["__scopeId","data-v-2d76ddb3"]]);var m=d},20548:function(e,t,l){var a=l(28782);t.A={data(){return{ownerSearch:"",filteredOwners:[],selectedOwner:null,isSearchingOwners:!1,isEditingOwner:!1,searchTimeout:null}},methods:{searchOwners(e){!e||e.length<2?this.filteredOwners=[]:(clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.isSearchingOwners=!0,this.$http.plain.get("/search-user/"+encodeURIComponent(e)).then(e=>{this.filteredOwners=e.data||[]}).catch(e=>{console.error(e)}).finally(()=>{this.isSearchingOwners=!1})},300))},selectOwner(e){e&&(this.selectedOwner=e,this.isEditingOwner=!1,this.ownerSearch="")},getUserAvatarUrl(e){return e&&e.logo?"demo_f"===e.logo?"https://randomuser.me/api/portraits/women/"+e.id%100+".jpg":"demo_m"===e.logo?"https://randomuser.me/api/portraits/men/"+e.id%100+".jpg":e.logo.contentUrl?a.ze+a.DJ+"user/"+e.logo.contentUrl:a.ze+a.DJ+"user/"+e.logo:null},startEditingOwner(){this.isEditingOwner=!0,this.ownerSearch="",this.filteredOwners=[],this.$nextTick(()=>{this.$refs.ownerAutocomplete&&this.$refs.ownerAutocomplete.focus()})}}}},32734:function(e,t,l){l.r(t),l.d(t,{default:function(){return ae}});l(44114);var a=l(20641),o=l(90033),s=l(53751);const i={class:"o-mediumwidth"},r=["disabled"],n={key:0,class:"project-header-bar mb-5"},u={class:"has-text-weight-semibold is-size-5 has-text-dark"},c={class:"card p-5 mb-5"},d={class:"columns is-multiline"},m={class:"column is-12"},p={style:{"max-width":"50%"}},h={class:"icon-type-row"},b={class:"icon-type-toggle"},f={key:0,class:"icon-type-value"},g={key:0,class:"emoji-trigger-preview"},v={key:1,class:"icon-type-value"},k=["value"],y={class:"modal-card emoji-modal-card"},w={class:"modal-card-head"},C={class:"modal-card-title"},$={class:"modal-card-body"},L={class:"emoji-picker-wrapper"},V={class:"column is-12"},_={class:"card p-5 mb-5"},j={class:"columns is-multiline"},S={class:"column is-12-mobile is-6-tablet"},E={class:"owner-info"},x={class:"image is-36x36",style:{"min-width":"36px"}},T=["src"],O={key:1,class:"avatar-placeholder is-rounded",style:{width:"36px",height:"36px"}},P={class:"owner-name"},F={class:"icon is-small"},G={class:"owner-option"},U={class:"image is-32x32"},A=["src"],X={key:1,class:"avatar-placeholder is-rounded"},W={class:"column is-12"},D={class:"help"},I={class:"card p-5 mb-5"},N={class:"has-text-weight-semibold mb-4"},z={class:"columns is-multiline"},B={class:"column is-12"},M={class:"is-flex is-flex-wrap-wrap",style:{gap:"1.5rem"}},R={key:1,class:"buttons is-justify-content-flex-end"},Q=["disabled"];function q(e,t,l,q,H,J){const K=(0,a.g2)("b-loading"),Y=(0,a.g2)("MobileViewHeader"),Z=(0,a.g2)("b-input"),ee=(0,a.g2)("b-field"),te=(0,a.g2)("font-awesome-icon"),le=(0,a.g2)("ColorPicker"),ae=(0,a.g2)("EmojiPicker"),oe=(0,a.g2)("b-modal"),se=(0,a.g2)("b-autocomplete"),ie=(0,a.g2)("b-taginput"),re=(0,a.g2)("b-checkbox");return(0,a.uX)(),(0,a.CE)("div",i,[(0,a.bF)(K,{modelValue:H.isLoading,"onUpdate:modelValue":t[0]||(t[0]=e=>H.isLoading=e),"is-full-page":!1},null,8,["modelValue"]),(0,a.bF)(Y,{title:e.$t("New project"),"back-route":"ProjectList"},{actions:(0,a.k6)(()=>[(0,a.Lk)("button",{class:(0,o.C4)(["button is-small is-rounded is-primary",{"is-loading":H.isSaving}]),disabled:!H.form.name,onClick:t[1]||(t[1]=(...e)=>J.save&&J.save(...e))},(0,o.v_)(e.$t("Create")),11,r)]),_:1},8,["title"]),e.$isMobile()?(0,a.Q3)("",!0):((0,a.uX)(),(0,a.CE)("div",n,[(0,a.Lk)("div",u,(0,o.v_)(e.$t("New project")),1)])),(0,a.Lk)("div",c,[(0,a.Lk)("div",d,[(0,a.Lk)("div",m,[(0,a.Lk)("div",p,[(0,a.bF)(ee,{label:e.$t("Project name"),type:H.errors.name?"is-danger":"",message:H.errors.name},{default:(0,a.k6)(()=>[(0,a.bF)(Z,{ref:"nameInput",modelValue:H.form.name,"onUpdate:modelValue":t[2]||(t[2]=e=>H.form.name=e),placeholder:e.$t("Enter project name"),onInput:t[3]||(t[3]=e=>H.errors.name=null)},null,8,["modelValue","placeholder"])]),_:1},8,["label","type","message"]),(0,a.Lk)("div",h,[(0,a.Lk)("div",b,[(0,a.Lk)("button",{type:"button",class:(0,o.C4)(["icon-type-btn",{"is-active":"emoji"===H.iconType}]),onClick:t[4]||(t[4]=e=>J.switchIconType("emoji"))},[(0,a.bF)(te,{icon:"fa-light fa-smile"}
1),(0,a.Lk)("span",null,(0,o.v_)(e.$t("Emoji")),1)],2),(0,a.Lk)("button",{type:"button",class:(0,o.C4)(["icon-type-btn",{"is-active":"color"===H.iconType}]),onClick:t[5]||(t[5]=e=>J.switchIconType("color"))},[(0,a.bF)(te,{icon:"fa-light fa-palette"}),(0,a.Lk)("span",null,(0,o.v_)(e.$t("Color")),1)],2)]),"emoji"===H.iconType?((0,a.uX)(),(0,a.CE)("div",f,[(0,a.Lk)("button",{type:"button",class:"emoji-trigger-btn",onClick:t[6]||(t[6]=e=>{H.showEmojiPicker=!0,J.focusEmojiSearch()})},[H.form.icon?((0,a.uX)(),(0,a.CE)("span",g,(0,o.v_)(H.form.icon),1)):((0,a.uX)(),(0,a.Wv)(te,{key:1,icon:"fa-light fa-plus",class:"has-text-grey"}))]),H.form.icon?((0,a.uX)(),(0,a.CE)("button",{key:0,type:"button",class:"button is-small is-rounded is-light",onClick:t[7]||(t[7]=e=>H.form.icon=null)},[(0,a.bF)(te,{icon:"fa-light fa-times"})])):(0,a.Q3)("",!0)])):((0,a.uX)(),(0,a.CE)("div",v,[(0,a.bF)(le,{"model-value":H.form.color,position:"is-bottom-left","button-size":"is-small","onUpdate:modelValue":t[8]||(t[8]=e=>H.form.color=e)},null,8,["model-value"]),(0,a.Lk)("label",{class:"custom-color-btn",style:(0,o.Tr)({backgroundColor:J.customColorPreview})},[(0,a.Lk)("input",{type:"color",value:J.customColorPreview,class:"custom-color-input",onInput:t[9]||(t[9]=e=>H.form.color=e.target.value)},null,40,k)],4)]))])])]),(0,a.bF)(oe,{modelValue:H.showEmojiPicker,"onUpdate:modelValue":t[11]||(t[11]=e=>H.showEmojiPicker=e),"has-modal-card":"","trap-focus":"","can-cancel":["escape","outside"]},{default:(0,a.k6)(()=>[(0,a.Lk)("div",y,[(0,a.Lk)("header",w,[(0,a.Lk)("p",C,(0,o.v_)(e.$t("Select emoji")),1),(0,a.Lk)("button",{type:"button",class:"delete",onClick:t[10]||(t[10]=e=>H.showEmojiPicker=!1)})]),(0,a.Lk)("section",$,[(0,a.Lk)("div",L,[(0,a.bF)(ae,{native:!0,theme:e.$store.state.theme,"disable-skin-tones":!0,onSelect:J.selectEmoji},null,8,["theme","onSelect"])])])])]),_:1},8,["modelValue"]),(0,a.Lk)("div",V,[(0,a.bF)(ee,{label:e.$t("Description")},{default:(0,a.k6)(()=>[(0,a.bF)(Z,{modelValue:H.form.description,"onUpdate:modelValue":t[12]||(t[12]=e=>H.form.description=e),type:"textarea",placeholder:e.$t("Describe the project goals and scope"),rows:"2"},null,8,["modelValue","placeholder"])]),_:1},8,["label"])])])]),(0,a.Lk)("div",_,[(0,a.Lk)("div",j,[(0,a.Lk)("div",S,[(0,a.bF)(ee,{label:e.$t("Project owner")},{default:(0,a.k6)(()=>[e.selectedOwner&&!e.isEditingOwner?((0,a.uX)(),(0,a.CE)("div",{key:0,class:"owner-selected",onClick:t[14]||(t[14]=(...t)=>e.startEditingOwner&&e.startEditingOwner(...t))},[(0,a.Lk)("div",E,[(0,a.Lk)("figure",x,[e.getUserAvatarUrl(e.selectedOwner)?((0,a.uX)(),(0,a.CE)("img",{key:0,src:e.getUserAvatarUrl(e.selectedOwner),class:"is-rounded",style:{width:"36px",height:"36px","object-fit":"cover"}},null,8,T)):((0,a.uX)(),(0,a.CE)("span",O,(0,o.v_)(e.selectedOwner.firstName?.charAt(0))+(0,o.v_)(e.selectedOwner.lastName?.charAt(0)),1))]),(0,a.Lk)("span",P,(0,o.v_)(e.selectedOwner.fullName),1)]),(0,a.Lk)("button",{type:"button",class:"button is-small is-rounded is-light",onClick:t[13]||(t[13]=(0,s.D$)((...t)=>e.startEditingOwner&&e.startEditingOwner(...t),["stop"]))},[(0,a.Lk)("span",F,[(0,a.bF)(te,{icon:"fa-light fa-pen"})]),(0,a.Lk)("span",null,(0,o.v_)(e.$t("Change")),1)])])):((0,a.uX)(),(0,a.Wv)(se,{key:1,ref:"ownerAutocomplete",modelValue:e.ownerSearch,"onUpdate:modelValue":t[15]||(t[15]=t=>e.ownerSearch=t),data:e.filteredOwners,placeholder:e.$t("Search by name"),field:"fullName",loading:e.isSearchingOwners,icon:"magnifying-glass","icon-pack":"fa-light","clear-on-select":!0,onTyping:e.searchOwners,onSelect:e.selectOwner},{default:(0,a.k6)(({option:t})=>[(0,a.Lk)("div",G,[(0,a.Lk)("figure",U,[e.getUserAvatarUrl(t)?((0,a.uX)(),(0,a.CE)("img",{key:0,src:e.getUserAvatarUrl(t),class:"is-rounded"},null,8,A)):((0,a.uX)(),(0,a.CE)("span",X,(0,o.v_)(t.firstName?.charAt(0))+(0,o.v_)(t.lastName?.charAt(0)),1))]),(0,a.Lk)("span",null,(0,o.v_)(t.fullName),1)])]),empty:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("No results found")),1)]),_:1},8,["modelValue","data","placeholder","loading","onTyping","onSelect"]))]),_:1},8,["label"])]),(0,a.Lk)("div",W,[(0,a.bF)(ee,{label:e.$t("Group access")},{default:(0,a.k6)(()=>[(0,a.bF)(ie,{modelValue:H.selectedGroups,"onUpdate:modelValue":t[16]||(t[16]=e=>H.selectedGroups=e),data:H.filteredGroups,autocomplete:"",field:"name","open-on-focus":!0,placeholder:e.$t("Select groups..."),onTyping:J.filterGroups},{default:(0,a.k6)(({option:e})=>[(0,a.Lk)("span",null,(0,o.v_)(e.name),1)]),empty:(0,a.k6)(()=>
1[(0,a.eW)((0,o.v_)(e.$t("No groups found")),1)]),_:1},8,["modelValue","data","placeholder","onTyping"])]),_:1},8,["label"]),(0,a.Lk)("p",D,(0,o.v_)(e.$t("Members of selected groups will have access to this project")),1)])])]),(0,a.Lk)("div",I,[(0,a.Lk)("p",N,(0,o.v_)(e.$t("Task options")),1),(0,a.Lk)("div",z,[(0,a.Lk)("div",B,[(0,a.Lk)("div",M,[(0,a.bF)(re,{modelValue:H.settings.hasGoals,"onUpdate:modelValue":t[17]||(t[17]=e=>H.settings.hasGoals=e)},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Goals")),1)]),_:1},8,["modelValue"]),(0,a.bF)(re,{modelValue:H.settings.hasPriority,"onUpdate:modelValue":t[18]||(t[18]=e=>H.settings.hasPriority=e)},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Priority")),1)]),_:1},8,["modelValue"]),(0,a.bF)(re,{modelValue:H.settings.hasDueDate,"onUpdate:modelValue":t[19]||(t[19]=e=>H.settings.hasDueDate=e)},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Due date")),1)]),_:1},8,["modelValue"]),(0,a.bF)(re,{modelValue:H.settings.hasTypes,"onUpdate:modelValue":t[20]||(t[20]=e=>H.settings.hasTypes=e)},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Task types")),1)]),_:1},8,["modelValue"]),(0,a.bF)(re,{modelValue:H.settings.hasStatus,"onUpdate:modelValue":t[21]||(t[21]=e=>H.settings.hasStatus=e)},{default:(0,a.k6)(()=>[(0,a.eW)((0,o.v_)(e.$t("Custom statuses")),1)]),_:1},8,["modelValue"])])])])]),e.$isMobile()?(0,a.Q3)("",!0):((0,a.uX)(),(0,a.CE)("div",R,[(0,a.Lk)("button",{class:"button is-light is-rounded",onClick:t[22]||(t[22]=t=>e.$router.push({name:"ProjectList"}))},(0,o.v_)(e.$t("Cancel")),1),(0,a.Lk)("button",{class:(0,o.C4)(["button is-primary is-rounded",{"is-loading":H.isSaving}]),disabled:!H.form.name,onClick:t[23]||(t[23]=(...e)=>J.save&&J.save(...e))},(0,o.v_)(e.$t("Create project")),11,Q)]))])}l(18111),l(22489),l(61701);var H=l(40834),J=l(81084),K=l(1068),Y=l(51114),Z=l(20548),ee={name:"ProjectCreate",components:{MobileViewHeader:J.A,ColorPicker:K.A,EmojiPicker:Y.A},mixins:[Z.A],data(){return{isLoading:!1,isSaving:!1,showEmojiPicker:!1,iconType:"color",form:{name:"",description:"",color:"indigo",icon:null,objectivesEnabled:!0},settings:{hasGoals:!1,hasPriority:!0,hasDueDate:!0,hasTypes:!0,hasStatus:!0},errors:{},availableGroups:[],filteredGroups:[],selectedGroups:[]}},computed:{...(0,H.L8)(["tenant","user","isGranted"]),customColorPreview(){const e=this.form.color;if(!e)return"#6366f1";if(e.startsWith("#"))return e;const t={slate:"#64748b",zinc:"#71717a",red:"#ef4444",orange:"#f97316",amber:"#f59e0b",yellow:"#eab308",lime:"#84cc16",olive:"#6b7234",green:"#22c55e",emerald:"#10b981","baby-blue":"#7dd3fc",cyan:"#06b6d4",sky:"#0ea5e9",blue:"#3b82f6",teal:"#14b8a6",indigo:"#6366f1",violet:"#8b5cf6",purple:"#a855f7",fuchsia:"#d946ef",pink:"#ec4899",rose:"#f43f5e"};return t[e]||"#6366f1"}},created(){this.selectedOwner=this.user,this.ownerSearch=this.user.fullName,this.fetchGroups()},mounted(){this.$nextTick(()=>{this.$refs.nameInput?.focus()})},methods:{fetchGroups(){this.$http.plain.get("/my-groups").then(e=>{this.availableGroups=e.data["hydra:member"]||[],this.filteredGroups=this.availableGroups}).catch(e=>{console.error(e)})},filterGroups(e){if(!e)return void(this.filteredGroups=this.availableGroups);const t=e.toLowerCase();this.filteredGroups=this.availableGroups.filter(e=>e.name&&e.name.toLowerCase().includes(t))},switchIconType(e){this.iconType=e,"color"===e&&(this.form.icon=null)},focusEmojiSearch(){setTimeout(()=>{const e=document.querySelector(".emoji-modal-card .v3-search input");e&&e.focus()},150)},selectEmoji(e){this.form.icon=e.i,this.showEmojiPicker=!1},save(){if(!this.form.name)return void(this.errors.name=this.$t("This field is required"));this.isSaving=!0;const e={name:this.form.name,description:this.form.description,color:this.form.color,icon:this.form.icon,owner:this.selectedOwner?this.selectedOwner["@id"]:null,objectivesEnabled:this.form.objectivesEnabled,settings:this.settings,groups:this.selectedGroups.map(e=>e["@id"])};this.$http.plain.post("/projects",e).then(e=>{this.$buefy.snackbar.open({message:this.$t("Project created successfully"),type:"is-success"}),this.$router.push({name:"ProjectShow",params:{id:e.data.uuid}})}).catch(e=>{console.error(e),this.$buefy.snackbar.open({message:this.$t("Failed to create project"),type:"is-danger"})}).finally(()=>{this.isSaving=!1})}}},te=l(66262);const le=(0,te.A)(ee,[["render",q],["__scopeId","data-v-bec590a6"]]);var ae=le}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.