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packs/application.js","webpack://aspadmin/./app/javascript/packs/controllers/application.js","webpack://aspadmin/./app/javascript/packs/controllers/index.js","webpack://aspadmin/./app/javascript/packs/controllers/tickets/edit_controller.js","webpack://aspadmin/./app/javascript/packs/controllers/tickets/form_submit_controller.js","webpack://aspadmin/./app/javascript/packs/controllers/tickets/modal_controller.js","webpack://aspadmin/./app/javascript/packs/firebase_initialization.js"],"sourcesContent":["/* eslint no-console:0 */\n// This file is automatically compiled by Webpack, along with any other files\n// present in this directory. You're encouraged to place your actual application logic in\n// a relevant structure within app/javascript and only use these pack files to reference\n// that code so it'll be compiled.\n//\n// To reference this file, add <%= javascript_pack_tag 'application' %> to the appropriate\n// layout file, like app/views/layouts/application.html.erb\n\n// Support component names relative to this directory:\nimport \"./firebase_initialization\"\nvar componentRequireContext = require.context(\"components\", true);\nvar ReactRailsUJS = require(\"react_ujs\");\nReactRailsUJS.useContext(componentRequireContext);\nimport \"@hotwired/turbo-rails\"\nimport \"./controllers\"\nimport { Turbo } from \"@hotwired/turbo-rails\"\nTurbo.session.drive = false","import { Application } from \"@hotwired/stimulus\"\n\nconst application = Application.start()\n\n// Configure Stimulus development experience\napplication.debug = true\nwindow.Stimulus = application\n\nexport { application }","// This file is auto-generated by ./bin/rails stimulus:manifest:update\n// Run that command whenever you add a new controller or create them with\n// ./bin/rails generate stimulus controllerName\nimport { application } from \"./application.js\"\nimport ModalController from \"./tickets/modal_controller.js\"\nimport TicketEditController from \"./tickets/edit_controller.js\"\nimport TicketFormSubmitController from \"./tickets/form_submit_controller.js\"\n\napplication.register(\"modal\", ModalController)\napplication.register(\"ticket-edit\", TicketEditController)\napplication.register(\"form-submit\", TicketFormSubmitController)","import { Controller } from \"@hotwired/stimulus\"\n\nexport default class extends Controller {\n static values = { id: Number, url: String }\n\n connect() {\n this.flexCells = document.querySelectorAll('.flex-cell.record');\n }\n\n displayForm() {\n document.getElementById(`ticket_edit_${this.idValue}`).src = this.urlValue;\n }\n\n changeBorderColor(event) {\n if (['SPAN', 'A'].includes(event.target.tagName)) return;\n\n const targetIsJustified = event.target.classList.contains('justify-content-between');\n const targetElement = targetIsJustified ? event.target.parentElement : event.target;\n const hasBorder = ['2px solid rgb(64, 158, 255)', '2px solid #409eff'].includes(targetElement.style.border);\n\n if (hasBorder) {\n this.displayForm();\n } else {\n this.flexCells.forEach(cell => cell.style.border = '1px solid #d8d8d8');\n if(event.target.classList.contains('justify-content-between')) {\n event.target.parentElement.style.border = '2px solid #409eff';\n } else {\n event.target.style.border = '2px solid #409eff';\n }\n }\n }\n\n changeColor() {\n const frame = document.getElementById(`ticket_edit_${this.idValue}`);\n const cells = frame.querySelectorAll('.flex-cell.record');\n cells.forEach(cell => cell.style.backgroundColor = '#fafafa');\n cells.forEach(cell => cell.style.cursor = 'pointer');\n }\n\n resetColor() {\n const frame = document.getElementById(`ticket_edit_${this.idValue}`);\n const cells = frame.querySelectorAll('.flex-cell.record');\n cells.forEach(cell => cell.style.backgroundColor = '#ffffff'); \n }\n}","import { Controller } from \"@hotwired/stimulus\"\n\nexport default class extends Controller {\n connect() {\n this.clickOutsideHandler = this.submitOutside.bind(this);\n document.addEventListener(\"click\", this.clickOutsideHandler);\n }\n\n disconnect() {\n document.removeEventListener(\"click\", this.clickOutsideHandler);\n }\n\n submitOutside(event) {\n if (!['INPUT', 'SELECT'].includes(event.target.tagName)) {\n const form = this.element.querySelector(\"form\");\n if (form) {\n const submitEvent = new CustomEvent('submit', {\n bubbles: true, \n cancelable: true \n });\n form.dispatchEvent(submitEvent);\n if (submitEvent.defaultPrevented) {\n form.requestSubmit(); \n }\n }\n }\n }\n}\n","import { Controller } from \"@hotwired/stimulus\"\n\nexport default class extends Controller {\n static targets = [\"modal\", \"overlay\", \"flashContainer\"];\n\n connect() {\n this.closeFunction = () => {\n this.close();\n this.showFlashMessage(\"施策を追加しました\", \"success\");\n };\n document.addEventListener(\"modal:close\", this.closeFunction);\n }\n\n open() {\n this.modalTarget.classList.add(\"show\");\n this.modalTarget.style.display = \"block\";\n this.overlayTarget.style.display = \"block\";\n this.modalTarget.removeAttribute(\"aria-hidden\");\n this.modalTarget.setAttribute(\"aria-modal\", true);\n this.modalTarget.setAttribute(\"role\", \"dialog\");\n }\n\n close() {\n this.modalTarget.classList.remove(\"show\");\n this.modalTarget.style.display = \"none\";\n this.overlayTarget.style.display = \"none\";\n this.modalTarget.setAttribute(\"aria-hidden\", true);\n this.modalTarget.removeAttribute(\"aria-modal\");\n this.modalTarget.removeAttribute(\"role\");\n }\n\n showFlashMessage(message, type) {\n const flashMessage = document.createElement(\"div\");\n flashMessage.className = `alert alert-${type}`;\n flashMessage.role = \"alert\";\n flashMessage.textContent = message;\n\n this.flashContainerTarget.appendChild(flashMessage);\n setTimeout(() => {\n flashMessage.remove();\n }, 3000);\n }\n}","if (firebase.apps.length === 0) {\n firebase.initializeApp({\n apiKey: process.env.API_KEY,\n authDomain: process.env.AUTH_DOMAIN,\n projectId: process.env.PROJECT_ID,\n storageBucket: process.env.STORAGE_BUCKET,\n messagingSenderId: process.env.MESSAGING_SENDER_ID,\n appId: process.env.APP_ID,\n measurementId: process.env.MEASUREMENT_ID,\n });\n}"],"names":["componentRequireContext","require","useContext","Turbo","drive","application","Application","start","debug","window","Stimulus","register","ModalController","TicketEditController","TicketFormSubmitController","_default","_Controller","_classCallCheck","_callSuper","arguments","_inherits","key","value","this","flexCells","document","querySelectorAll","getElementById","concat","idValue","src","urlValue","event","includes","target","tagName","targetElement","classList","contains","parentElement","style","border","displayForm","forEach","cell","cells","backgroundColor","cursor","Controller","values","id","Number","url","String","clickOutsideHandler","submitOutside","bind","addEventListener","removeEventListener","form","element","querySelector","submitEvent","CustomEvent","bubbles","cancelable","dispatchEvent","defaultPrevented","requestSubmit","_this","closeFunction","close","showFlashMessage","modalTarget","add","display","overlayTarget","removeAttribute","setAttribute","remove","message","type","flashMessage","createElement","className","role","textContent","flashContainerTarget","appendChild","setTimeout","targets","firebase","apps","length","initializeApp","apiKey","process","authDomain","projectId","storageBucket","messagingSenderId","appId","measurementId"],"sourceRoot":""}