1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[9361],{40681:(e,l,s)=>{s.d(l,{A:()=>t});var n=s(45627),a=s.n(n),i=s(76798),o=s.n(i)()(a());o.push([e.id,".help[data-v-f18670de]{font-style:italic}.field[data-v-f18670de]{margin-top:1.5rem}.poll-creation-wrapper[data-v-f18670de]{height:0;overflow:hidden}.poll-creation-wrapper.is-opened[data-v-f18670de]{height:auto}.advanced-options-wrapper[data-v-f18670de]{height:0;overflow:hidden}.advanced-options-wrapper.is-opened[data-v-f18670de]{height:auto}.has-small-datepicker>div[data-v-f18670de]{display:inline-block}","",{version:3,sources:["webpack://./resources/js/components/Tools/AddPoll.vue"],names:[],mappings:"AAgWA,uBACA,iBACA,CACA,wBACA,iBACA,CACA,wCACA,QAAA,CACA,eACA,CACA,kDACA,WACA,CAEA,2CACA,QAAA,CACA,eACA,CACA,qDACA,WACA,CACA,2CACA,oBACA",sourcesContent:['<template>\n\n <div class="field">\n <div :class=" poll ? \'\' : \'field is-horizontal\' ">\n <div v-show=" ! poll " class="field-label">\n <label for="AttachPoll" class="label">Attach a Poll?</label>\n </div>\n <div class="field-body is-block">\n <label v-show=" ! poll " class="xero-checkbox">\n <xero-checkbox id="AttachPoll" @change="(data) => {opened = data === \'Yes\';}" name="AttachPoll" value="Yes"></xero-checkbox>\n <span></span>\n </label>\n <div class="poll-creation-wrapper" :class=" opened || poll ? \'is-opened\' : \'\' ">\n <div v-show=" ! poll ">\n <br>\n <div class="is-divider"></div>\n </div>\n <div>\n <h2 v-show=" ! poll " class="title is-4 has-text-centered">Create a poll</h2>\n <div class="field my-4">\n <div class="label">\n <label for="question" class="label">Question</label>\n </div>\n <div class="control">\n <xero-input type="text" class="input" id="question" name="question" :value=" poll && poll.question ? poll.question : \'\' " placeholder="Poll Question/Title"></xero-input>\n </div>\n </div>\n\n <fieldset v-show=" ! poll " class="field my-4">\n <legend class="label">\n <label class="label">Add Options</label>\n </legend>\n <div class="control">\n <ul>\n <li v-for="(input, index) in inputs" class="field has-addons" style="margin-bottom:0;margin-top: 0.25rem;">\n <div class="control is-expanded">\n <xero-input type="text" class="input is-fullwidth" :name="\'PollOptions[\' + index + \']\'" :value="input ? input : \'\'" placeholder="Enter a polling option..."></xero-input>\n </div>\n <div class="control">\n <button class="button is-danger is-light" type="button" @click="deleteOption(index)">X</button>\n </div>\n </li>\n </ul>\n <button type="button" class="button is-light is-primary is-small" @click="addPollOption">Add Option</button>\n </div>\n </fieldset>\n\n <div class="field my-4">\n <label class="xero-checkbox">\n View Advanced Options\n <xero-checkbox id="advanced-poll-options" @change="(data) => {advancedOptionsOpened = data === \'Yes\';}" :checked=" poll ? \'checked\' : false " name="AdvancedOptions" value="Yes"></xero-checkbox>
1\n <span></span>\n </label>\n </div>\n <div class="advanced-options-wrapper" :class=" advancedOptionsOpened ? \'is-opened\' : \'\' ">\n <br>\n <fieldset class="field my-4">\n <legend class="label">\n <label for="votingPrivilege" class="label">Who can vote?</label>\n </legend>\n <div class="control">\n <p class="help">Who is allowed to submit a vote on this Poll? This does NOT affect the visibility of the poll however!</p>\n <p class="select">\n <xero-select required name="votingPrivilege" id="votingPrivilege"\n :options="{\n \'1\': \'Members Only\',\n \'2\': \'Active Members Only\',\n \'3\': \'Volunteers Only\',\n \'6\': \'Leadership Only\',\n \'7\': \'Administrators Only\'\n }"\n :defaultOption=" poll && poll.votingPrivilege ? poll.votingPrivilege : \'1\'">\n </xero-select>\n </p>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="maxVotesPerUser" class="label">Votes per User?</label>\n </legend>\n <div class="control">\n <p class="help">How many selections can a user make on the form?</p>\n <xero-input type="number" class="input is-small" min="0" :value=" poll && poll.maxVotesPerUser ? poll.maxVotesPerUser : 5 " name="maxVotesPerUser" id="maxVotesPerUser"></xero-input>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="userSubmissions" class="label">Submissions?</label>\n </legend>\n <div class="control">\n <p class="help">Can the user submit new poll options?</p>\n <div class="py-1">\n <label class="xero-radio">\n Yes\n <xero-radio name="userSubmissions" id="userSubmissions" :checked=" !poll || poll.userSubmissions === 1 ? \'checked\' : false " value="1"></xero-radio>\n <span></span>\n </label>\n </div>\n <div class="py-1">\n <label class="xero-radio">\n No\n <xero-radio name="userSubmissions" :checked=" poll && poll.userSubmissions === 0 ? \'checked\' : false " value="
10"></xero-radio>\n <span></span>\n </label>\n </div>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="expiration" class="label">Poll Expiration</label>\n </legend>\n <div class="control is-block">\n\n <p class="help">When does the poll close or expire?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" id="expiration" :checked=" ! poll || poll.expiration === \'Never\' ? \'checked\' : \'\' " value="Never"></xero-radio>\n <span></span>\n Never\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1 is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'Date\' ? \'checked\' : false " value="Date"></xero-radio>\n <span></span>\n At the end of the day on:\n </label>\n </div>\n <div class="control has-small-datepicker">\n <VueCtkDateTimePicker\n v-model="pollExpirationDate"\n :only-date="true"\n formatted="ll"\n format="YYYY-MM-DD HH:mm:ss" />\n <input type="hidden" name="poll-expiration-Date" :value=" $outputDate(pollExpirationDate, \'YYYY-MM-DD\') " />\n </div>\n </div>\n\n <div class="py-1">\n <div class="field is-marginless is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'After\' ? \'checked\' : false " value="After"></xero-radio>\n <span></span>\n After XX votes are collected:\n </label>\n </div>\n <div class="control">\n <xero-input name="poll-expiration-After" type="number" min="1" :value=" poll && poll.expiration === \'After\' ? poll.expiration_meta : 10 " class="input is-small"></xero-input>\n </div>\n </div>\n </div>\n\n <div class="field is-marginless py-1 is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'Goal\' ? \'checked\' : false " value="Goal"></xero-radio>
1\n <span></span>\n Once a section reaches XX votes:\n </label>\n </div>\n <div class="control">\n <xero-input name="poll-expiration-Goal" type="number" min="1" :value=" poll && poll.expiration === \'Goal\' ? poll.expiration_meta : 10 " class="input is-small"></xero-input>\n </div>\n </div>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="showResults" class="label">Poll Results</label>\n </legend>\n <div class="control is-block">\n <p class="help">When should the results of the poll be displayed to everyone?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" id="showResults" :checked=" ! poll || poll.showResults === \'Never\' ? \'checked\' : false " value="Never"></xero-radio>\n <span></span>\n Never\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'Always\' ? \'checked\' : false " value="Always"></xero-radio>\n <span></span>\n Always\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'After\' ? \'checked\' : false " value="After"></xero-radio>\n <span></span>\n After they vote\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'Close\' ? \'checked\' : false " value="Close"></xero-radio>\n <span></span>\n After the poll closes\n </label>\n </div>\n </div>\n\n\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="changeVote" class="label">Change Votes?</label>\n </legend>\n <div class="control is-block">\n <p class="help">Can the user retract or change their vote?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="changeVote" id="changeVote" :checked=" poll && poll.changeVote === 1 ? \'checked\' : false " value="1"></xero-radio>
1 <span></span>\n Yes\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="changeVote" :checked=" !poll || poll.changeVote === 0 ? \'checked\' : false " value="0"></xero-radio>\n <span></span>\n No\n </label>\n </div>\n </div>\n\n </div>\n </fieldset>\n\n </div>\n </div>\n <div class="is-divider"></div>\n </div>\n </div>\n </div>\n </div>\n\n\n</template>\n\n\n<script>\n export default {\n name: \'Add-Poll\',\n props: {\n poll: {\
1n type: Object,\n required: false\n },\n },\n data() {\n return {\n xPoll: this.poll || {},\n inputs: [\'\', \'\', \'\'],\n opened: \'\',\n advancedOptionsOpened: \'\',\n pollExpiration: \'Never\',\n pollExpirationDate: this.poll && this.poll.expiration === \'Date\' ? this.$outputDate(new Date(this.poll.expiration_meta), \'YYYY-MM-DD HH:mm:ss\') : this.$moment().add(\'3\', \'days\').format(\'YYYY-MM-DD HH:mm:ss\')\n }\n },\n methods: {\n addPollOption: function() {\n this.inputs.push(\'\');\n },\n deleteOption(index) {\n this.inputs.splice(index, 1);\n },\n },\n mounted() {\n if(this.$store.state.old.PollOptions) {\n if(this.$store.state.old.PollOptions.length) {\n this.inputs = this.$store.state.old.PollOptions;\n }\n }\n },\n }\n<\/script>\n\n<style scoped>\n .help {\n font-style: italic;\n }\n .field {\n margin-top: 1.5rem;\n }\n .poll-creation-wrapper {\n height: 0;\n overflow: hidden;\n }\n .poll-creation-wrapper.is-opened {\n height: auto;\n }\n\n .advanced-options-wrapper {\n height: 0;\n overflow: hidden;\n }\n .advanced-options-wrapper.is-opened {\n height: auto;\n }\n .has-small-datepicker > div {\n display: inline-block;\n }\n</style>\n\n<style>\n .has-small-datepicker .vmdtp_label {\n font-size: 0.75rem;\n }\n .has-small-datepicker .vmdtp_label .vmdtp_input {\n width: auto;\n padding: 6px 7px;\n border: 1px solid #dbdbdb;\n border-radius: 2px;\n font-size: 0.75rem;\n box-shadow: inset 0 0.0625em 0.125em rgb(10 10 10 / 5%);\n }\n\n</style>\n'],sourceRoot:""}]);const t=o},13857:(e,l,s)=>{s.d(l,{A:()=>t});var n=s(45627),a=s.n(n),i=s(76798),o=s.n(i)()(a());o.push([e.id,".has-small-datepicker .vmdtp_label{font-size:.75rem}.has-small-datepicker .vmdtp_label .vmdtp_input{border:1px solid #dbdbdb;border-radius:2px;box-shadow:inset 0 .0625em .125em hsla(0,0%,4%,.05);font-size:.75rem;padding:6px 7px;width:auto}","",{version:3,sources:["webpack://./resources/js/components/Tools/AddPoll.vue"],names:[],mappings:"AAgWA,mCACA,gBACA,CACA,gDAGA,wBAAA,CACA,iBAAA,CAEA,mDAAA,CADA,gBAAA,CAHA,eAAA,CADA,UAMA",sourcesContent:['<template>\n\n <div class="field">\n <div :class=" poll ? \'\' : \'field is-horizontal\' ">\n <div v-show=" ! poll " class="field-label">\n <label for="AttachPoll" class="label">Attach a Poll?</label>\n </div>\n <div class="field-body is-block">\n <label v-show=" ! poll " class="xero-checkbox">\n <xero-checkbox id="AttachPoll" @change="(data) => {opened = data === \'Yes\';}" name="AttachPoll" value="Yes"></xero-checkbox>\n <span></span>\n </label>\n <div class="poll-creation-wrapper" :class=" opened || poll ? \'is-opened\' : \'\' ">\n <div v-show=" ! poll ">\n <br>\n <div class="is-divider"></div>\n </div>\n <div>\n <h2 v-show=" ! poll " class="title is-4 has-text-centered">Create a poll</h2>\n <div class="field my-4">\n <div class="label">\n <label for="question" class="label">Question</label>\n </div>\n <div class="control">\n <xero-input type="text" class="input" id="question" name="question" :value=" poll && poll.question ? poll.question : \'\' " placeholder="Poll Question/Title"></xero-input>\n </div>\n </div>\n\n <fieldset v-show=" ! poll " class="field my-4">\n <legend class="label">\n <label class="label">Add Options</label>\n </legend>\n <div class="control">\n <ul>\n <li v-for="(input, index) in inputs" class="field has-addons" style="margin-bottom:0;margin-top: 0.25rem;">\n <div class="control is-expanded">\n <xero-input type="text" class="input is-fullwidth" :name="\'PollOptions[\' + index + \']\'" :value="input ? input : \'\'" placeholder="Enter a polling option..."></xero-input>\n </div>\n <div class="control">\n <button class="button is-danger is-light" type="button" @click="deleteOption(index)">X</button>\n </div>\n </li>\n </ul>\n <button type="button" class="button is-light is-primary is-small" @click="addPollOption">Add Option</button>\n </div>\n </fieldset>\n\n <div class="field my-4">\n <label class="xero-checkbox">\n View Advanced Options\n <xero-checkbox id="advanced-poll-options" @change="(data) => {advancedOptionsOpened = data === \'Yes\';}" :checked=" poll ? \'checked\' : false " name="AdvancedOptions" value="Yes"></xero-checkbox>
1\n <span></span>\n </label>\n </div>\n <div class="advanced-options-wrapper" :class=" advancedOptionsOpened ? \'is-opened\' : \'\' ">\n <br>\n <fieldset class="field my-4">\n <legend class="label">\n <label for="votingPrivilege" class="label">Who can vote?</label>\n </legend>\n <div class="control">\n <p class="help">Who is allowed to submit a vote on this Poll? This does NOT affect the visibility of the poll however!</p>\n <p class="select">\n <xero-select required name="votingPrivilege" id="votingPrivilege"\n :options="{\n \'1\': \'Members Only\',\n \'2\': \'Active Members Only\',\n \'3\': \'Volunteers Only\',\n \'6\': \'Leadership Only\',\n \'7\': \'Administrators Only\'\n }"\n :defaultOption=" poll && poll.votingPrivilege ? poll.votingPrivilege : \'1\'">\n </xero-select>\n </p>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="maxVotesPerUser" class="label">Votes per User?</label>\n </legend>\n <div class="control">\n <p class="help">How many selections can a user make on the form?</p>\n <xero-input type="number" class="input is-small" min="0" :value=" poll && poll.maxVotesPerUser ? poll.maxVotesPerUser : 5 " name="maxVotesPerUser" id="maxVotesPerUser"></xero-input>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="userSubmissions" class="label">Submissions?</label>\n </legend>\n <div class="control">\n <p class="help">Can the user submit new poll options?</p>\n <div class="py-1">\n <label class="xero-radio">\n Yes\n <xero-radio name="userSubmissions" id="userSubmissions" :checked=" !poll || poll.userSubmissions === 1 ? \'checked\' : false " value="1"></xero-radio>\n <span></span>\n </label>\n </div>\n <div class="py-1">\n <label class="xero-radio">\n No\n <xero-radio name="userSubmissions" :checked=" poll && poll.userSubmissions === 0 ? \'checked\' : false " value="
10"></xero-radio>\n <span></span>\n </label>\n </div>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="expiration" class="label">Poll Expiration</label>\n </legend>\n <div class="control is-block">\n\n <p class="help">When does the poll close or expire?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" id="expiration" :checked=" ! poll || poll.expiration === \'Never\' ? \'checked\' : \'\' " value="Never"></xero-radio>\n <span></span>\n Never\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1 is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'Date\' ? \'checked\' : false " value="Date"></xero-radio>\n <span></span>\n At the end of the day on:\n </label>\n </div>\n <div class="control has-small-datepicker">\n <VueCtkDateTimePicker\n v-model="pollExpirationDate"\n :only-date="true"\n formatted="ll"\n format="YYYY-MM-DD HH:mm:ss" />\n <input type="hidden" name="poll-expiration-Date" :value=" $outputDate(pollExpirationDate, \'YYYY-MM-DD\') " />\n </div>\n </div>\n\n <div class="py-1">\n <div class="field is-marginless is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'After\' ? \'checked\' : false " value="After"></xero-radio>\n <span></span>\n After XX votes are collected:\n </label>\n </div>\n <div class="control">\n <xero-input name="poll-expiration-After" type="number" min="1" :value=" poll && poll.expiration === \'After\' ? poll.expiration_meta : 10 " class="input is-small"></xero-input>\n </div>\n </div>\n </div>\n\n <div class="field is-marginless py-1 is-grouped">\n <div class="control">\n <label class="xero-radio">\n <xero-radio @change=" (data) => {pollExpiration = data;} " name="expiration" :checked=" poll && poll.expiration === \'Goal\' ? \'checked\' : false " value="Goal"></xero-radio>
1\n <span></span>\n Once a section reaches XX votes:\n </label>\n </div>\n <div class="control">\n <xero-input name="poll-expiration-Goal" type="number" min="1" :value=" poll && poll.expiration === \'Goal\' ? poll.expiration_meta : 10 " class="input is-small"></xero-input>\n </div>\n </div>\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="showResults" class="label">Poll Results</label>\n </legend>\n <div class="control is-block">\n <p class="help">When should the results of the poll be displayed to everyone?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" id="showResults" :checked=" ! poll || poll.showResults === \'Never\' ? \'checked\' : false " value="Never"></xero-radio>\n <span></span>\n Never\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'Always\' ? \'checked\' : false " value="Always"></xero-radio>\n <span></span>\n Always\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'After\' ? \'checked\' : false " value="After"></xero-radio>\n <span></span>\n After they vote\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="showResults" :checked=" poll && poll.showResults === \'Close\' ? \'checked\' : false " value="Close"></xero-radio>\n <span></span>\n After the poll closes\n </label>\n </div>\n </div>\n\n\n </div>\n </fieldset>\n\n <fieldset class="field my-4">\n <legend class="label">\n <label for="changeVote" class="label">Change Votes?</label>\n </legend>\n <div class="control is-block">\n <p class="help">Can the user retract or change their vote?</p>\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="changeVote" id="changeVote" :checked=" poll && poll.changeVote === 1 ? \'checked\' : false " value="1"></xero-radio>
1 <span></span>\n Yes\n </label>\n </div>\n </div>\n\n\n <div class="field is-marginless py-1">\n <div class="control">\n <label class="xero-radio">\n <xero-radio name="changeVote" :checked=" !poll || poll.changeVote === 0 ? \'checked\' : false " value="0"></xero-radio>\n <span></span>\n No\n </label>\n </div>\n </div>\n\n </div>\n </fieldset>\n\n </div>\n </div>\n <div class="is-divider"></div>\n </div>\n </div>\n </div>\n </div>\n\n\n</template>\n\n\n<script>\n export default {\n name: \'Add-Poll\',\n props: {\n poll: {\
1n type: Object,\n required: false\n },\n },\n data() {\n return {\n xPoll: this.poll || {},\n inputs: [\'\', \'\', \'\'],\n opened: \'\',\n advancedOptionsOpened: \'\',\n pollExpiration: \'Never\',\n pollExpirationDate: this.poll && this.poll.expiration === \'Date\' ? this.$outputDate(new Date(this.poll.expiration_meta), \'YYYY-MM-DD HH:mm:ss\') : this.$moment().add(\'3\', \'days\').format(\'YYYY-MM-DD HH:mm:ss\')\n }\n },\n methods: {\n addPollOption: function() {\n this.inputs.push(\'\');\n },\n deleteOption(index) {\n this.inputs.splice(index, 1);\n },\n },\n mounted() {\n if(this.$store.state.old.PollOptions) {\n if(this.$store.state.old.PollOptions.length) {\n this.inputs = this.$store.state.old.PollOptions;\n }\n }\n },\n }\n<\/script>\n\n<style scoped>\n .help {\n font-style: italic;\n }\n .field {\n margin-top: 1.5rem;\n }\n .poll-creation-wrapper {\n height: 0;\n overflow: hidden;\n }\n .poll-creation-wrapper.is-opened {\n height: auto;\n }\n\n .advanced-options-wrapper {\n height: 0;\n overflow: hidden;\n }\n .advanced-options-wrapper.is-opened {\n height: auto;\n }\n .has-small-datepicker > div {\n display: inline-block;\n }\n</style>\n\n<style>\n .has-small-datepicker .vmdtp_label {\n font-size: 0.75rem;\n }\n .has-small-datepicker .vmdtp_label .vmdtp_input {\n width: auto;\n padding: 6px 7px;\n border: 1px solid #dbdbdb;\n border-radius: 2px;\n font-size: 0.75rem;\n box-shadow: inset 0 0.0625em 0.125em rgb(10 10 10 / 5%);\n }\n\n</style>\n'],sourceRoot:""}]);const t=o},69361:(e,l,s)=>{s.r(l),s.d(l,{default:()=>p});const n={name:"Add-Poll",props:{poll:{type:Object,required:!1}},data:function(){return{xPoll:this.poll||{},inputs:["","",""],opened:"",advancedOptionsOpened:"",pollExpiration:"Never",pollExpirationDate:this.poll&&"Date"===this.poll.expiration?this.$outputDate(new Date(this.poll.expiration_meta),"YYYY-MM-DD HH:mm:ss"):this.$moment().add("3","days").format("YYYY-MM-DD HH:mm:ss")}},methods:{addPollOption:function(){this.inputs.push("")},deleteOption:function(e){this.inputs.splice(e,1)}},mounted:function(){this.$store.state.old.PollOptions&&this.$store.state.old.PollOptions.length&&(this.inputs=this.$store.state.old.PollOptions)}};var a=s(40100),i=s.n(a),o=s(40681),t={insert:"head",singleton:!1};i()(o.A,t);o.A.locals;var d=s(13857),r={insert:"head",singleton:!1};i()(d.A,r);d.A.locals;const p=(0,s(14486).A)(n,(function(){var e=this,l=e._self._c;return l("div",{staticClass:"field"},[l("div",{class:e.poll?"":"field is-horizontal"},[l("div",{directives:[{name:"show",rawName:"v-show",value:!e.poll,expression:" ! poll "}],staticClass:"field-label"},[l("label",{staticClass:"label",attrs:{for:"AttachPoll"}},[e._v("Attach a Poll?")])]),e._v(" "),l("div",{staticClass:"field-body is-block"},[l("label",{directives:[{name:"show",rawName:"v-show",value:!e.poll,expression:" ! poll "}],staticClass:"xero-checkbox"},[l("xero-checkbox",{attrs:{id:"AttachPoll",name:"AttachPoll",value:"Yes"},on:{change:function(l){e.opened="Yes"===l}}}),e._v(" "),l("span")],1),e._v(" "),l("div",{staticClass:"poll-creation-wrapper",class:e.opened||e.poll?"is-opened":""},[l("div",{directives:[{name:"show",rawName:"v-show",value:!e.poll,expression:" ! poll "}]},[l("br"),e._v(" "),l("div",{staticClass:"is-divider"})]),e._v(" "),l("div",[l("h2",{directives:[{name:"show",rawName:"v-show",value:!e.poll,expression:" ! poll "}],staticClass:"title is-4 has-text-centered"},[e._v("Create a poll")]),e._v(" "),l("div",{staticClass:"field my-4"},[e._m(0),e._v(" "),l("div",{staticClass:"control"},[l("xero-input",{staticClass:"input",attrs:{type:"text",id:"question",name:"question",value:e.poll&&e.poll.question?e.poll.question:"",placeholder:"Poll Question/Title"}})],1)]),e._v(" "),l("fieldset",{directives:[{name:"show",rawName:"v-show",value:!e.poll,expression:" ! poll "}],staticClass:"field my-4"},[e._m(1),e._v(" "),l("div",{staticClass:"control"}
1,[l("ul",e._l(e.inputs,(function(s,n){return l("li",{staticClass:"field has-addons",staticStyle:{"margin-bottom":"0","margin-top":"0.25rem"}},[l("div",{staticClass:"control is-expanded"},[l("xero-input",{staticClass:"input is-fullwidth",attrs:{type:"text",name:"PollOptions["+n+"]",value:s||"",placeholder:"Enter a polling option..."}})],1),e._v(" "),l("div",{staticClass:"control"},[l("button",{staticClass:"button is-danger is-light",attrs:{type:"button"},on:{click:function(l){return e.deleteOption(n)}}},[e._v("X")])])])})),0),e._v(" "),l("button",{staticClass:"button is-light is-primary is-small",attrs:{type:"button"},on:{click:e.addPollOption}},[e._v("Add Option")])])]),e._v(" "),l("div",{staticClass:"field my-4"},[l("label",{staticClass:"xero-checkbox"},[e._v("\n View Advanced Options\n "),l("xero-checkbox",{attrs:{id:"advanced-poll-options",checked:!!e.poll&&"checked",name:"AdvancedOptions",value:"Yes"},on:{change:function(l){e.advancedOptionsOpened="Yes"===l}}}),e._v(" "),l("span")],1)]),e._v(" "),l("div",{staticClass:"advanced-options-wrapper",class:e.advancedOptionsOpened?"is-opened":""},[l("br"),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(2),e._v(" "),l("div",{staticClass:"control"},[l("p",{staticClass:"help"},[e._v("Who is allowed to submit a vote on this Poll? This does NOT affect the visibility of the poll however!")]),e._v(" "),l("p",{staticClass:"select"},[l("xero-select",{attrs:{required:"",name:"votingPrivilege",id:"votingPrivilege",options:{1:"Members Only",2:"Active Members Only",3:"Volunteers Only",6:"Leadership Only",7:"Administrators Only"},defaultOption:e.poll&&e.poll.votingPrivilege?e.poll.votingPrivilege:"1"}})],1)])]),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(3),e._v(" "),l("div",{staticClass:"control"},[l("p",{staticClass:"help"},[e._v("How many selections can a user make on the form?")]),e._v(" "),l("xero-input",{staticClass:"input is-small",attrs:{type:"number",min:"0",value:e.poll&&e.poll.maxVotesPerUser?e.poll.maxVotesPerUser:5,name:"maxVotesPerUser",id:"maxVotesPerUser"}})],1)]),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(4),e._v(" "),l("div",{staticClass:"control"},[l("p",{staticClass:"help"},[e._v("Can the user submit new poll options?")]),e._v(" "),l("div",{staticClass:"py-1"},[l("label",{staticClass:"xero-radio"},[e._v("\n Yes\n "),l("xero-radio",{attrs:{name:"userSubmissions",id:"userSubmissions",checked:(!e.poll||1===e.poll.userSubmissions)&&"checked",value:"1"}}),e._v(" "),l("span")],1)]),e._v(" "),l("div",{staticClass:"py-1"},[l("label",{staticClass:"xero-radio"},[e._v("\n No\n "),l("xero-radio",{attrs:{name:"userSubmissions",checked:!(!e.poll||0!==e.poll.userSubmissions)&&"checked",value:"0"}}),e._v(" "),l("span")],1)])])]),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(5),e._v(" "),l("div",{staticClass:"control is-block"},[l("p",{staticClass:"help"},[e._v("When does the poll close or expire?")]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"expiration",id:"expiration",checked:e.poll&&"Never"!==e.poll.expiration?"":"checked",value:"Never"},on:{change:function(l){e.pollExpiration=l}}}),e._v(" "),l("span"),e._v("\n Never\n ")],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1 is-grouped"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"expiration",checked:!(!e.poll||"Date"!==e.poll.expiration)&&"checked",value:"Date"},on:{change:function(l){e.pollExpiration=l}}}),e._v(" "),l("span"),e._v("\n At the end of the day on:\n ")],1)]),e._v(" "),l("div",{staticClass:"control has-small-datepicker"},[l("VueCtkDateTimePicker",{attrs:{"only-date":!0,formatted:"ll",format:"YYYY-MM-DD HH:mm:ss"},model:{value:e.pollExpirationDate,callback:function(l){e.pollExpirationDate=l},expression:"pollExpirationDate"}}),e._v(" "),l("input",{attrs:{type:"hidden",name:"poll-expiration-Date"},domProps:{value:e.$outputDate(e.pollExpirationDate,"YYYY-MM-DD")}})],1)]),e._v(" "),l("div",{staticClass:"py-1"},[l("div",{staticClass:"field is-marginless is-grouped"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"expiration",checked:!(!e.poll||"After"!==e.poll.expiration)&&"checked",value:"After"},on:{change:function(l){e.pollExpiration=l}}}),e._v(" "),l("span"),e._v("\n After XX votes are collected:\n ")],1)]),e._v(" "),l("div",{staticClass:"control"},[l("xero-input",{staticClass:"input is-small",attrs:{name:"poll-expiration-After",type:"number",min:"1",value:e.poll&&"After"===e.poll.expiration?e.poll.expiration_meta:10}})],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1 is-grouped"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"expiration",checked:!(!e.poll||"Goal"!==e.poll.expiration)&&"checked",value:"Goal"},on:{change:function(l){e.pollExpiration=l}}}),e._v(" "),l("span"),e._v("\n Once a section reaches XX votes:\n ")],1)]),e._v(" "),l("div",{staticClass:"control"},[l("xero-input",{staticClass:"input is-small",attrs:{name:"poll-expiration-Goal",type:"number",min:"1",value:e.poll&&"Goal"===e.poll.expiration?e.poll.expiration_meta:10}})],1)])])]),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(6),e._v(" "),l("div",{staticClass:"control is-block"},[l("p",{staticClass:"help"},[e._v("When should the results of the poll be displayed to everyone?")]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"showResults",id:"showResults",checked:(!e.poll||"Never"===e.poll.showResults)&&"checked",value:"Never"}}),e._v(" "),l("span"),e._v("\n Never\n ")],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"showResults",checked:!(!e.poll||"Always"!==e.poll.showResults)&&"checked",value:"Always"}}
1),e._v(" "),l("span"),e._v("\n Always\n ")],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"showResults",checked:!(!e.poll||"After"!==e.poll.showResults)&&"checked",value:"After"}}),e._v(" "),l("span"),e._v("\n After they vote\n ")],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"showResults",checked:!(!e.poll||"Close"!==e.poll.showResults)&&"checked",value:"Close"}}),e._v(" "),l("span"),e._v("\n After the poll closes\n ")],1)])])])]),e._v(" "),l("fieldset",{staticClass:"field my-4"},[e._m(7),e._v(" "),l("div",{staticClass:"control is-block"},[l("p",{staticClass:"help"},[e._v("Can the user retract or change their vote?")]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"changeVote",id:"changeVote",checked:!(!e.poll||1!==e.poll.changeVote)&&"checked",value:"1"}}),e._v(" "),l("span"),e._v("\n Yes\n ")],1)])]),e._v(" "),l("div",{staticClass:"field is-marginless py-1"},[l("div",{staticClass:"control"},[l("label",{staticClass:"xero-radio"},[l("xero-radio",{attrs:{name:"changeVote",checked:(!e.poll||0===e.poll.changeVote)&&"checked",value:"0"}}),e._v(" "),l("span"),e._v("\n No\n ")],1)])])])])])]),e._v(" "),l("div",{staticClass:"is-divider"})])])])])}),[function(){var e=this._self._c;return e("div",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"question"}},[this._v("Question")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label"},[this._v("Add Options")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"votingPrivilege"}},[this._v("Who can vote?")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"maxVotesPerUser"}},[this._v("Votes per User?")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"userSubmissions"}},[this._v("Submissions?")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"expiration"}},[this._v("Poll Expiration")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"showResults"}},[this._v("Poll Results")])])},function(){var e=this._self._c;return e("legend",{staticClass:"label"},[e("label",{staticClass:"label",attrs:{for:"changeVote"}},[this._v("Change Votes?")])])}],!1,null,"f18670de",null).exports}}]); 2//# sourceMappingURL=9361.js.map?id=d0e7624f69145057
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.