{"version":3,"file":"js/application-7b3c7260a7cee84f9810.chunk.js","sources":["webpack:///./app/javascript/channels sync _channel\\.js$","webpack:///./app/javascript/channels/index.js","webpack:///./app/javascript/packs/application.js","webpack:///./app/javascript/packs/post_content_count.js","webpack:///./app/javascript/packs/swiper.js"],"sourcesContent":["function webpackEmptyContext(req) {\n\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\te.code = 'MODULE_NOT_FOUND';\n\tthrow e;\n}\nwebpackEmptyContext.keys = function() { return []; };\nwebpackEmptyContext.resolve = webpackEmptyContext;\nmodule.exports = webpackEmptyContext;\nwebpackEmptyContext.id = \"./app/javascript/channels sync recursive _channel\\\\.js$\";","// Load all the channels within this directory and all subdirectories.\n// Channel files must be named *_channel.js.\n\nconst channels = require.context('.', true, /_channel\\.js$/)\nchannels.keys().forEach(channels)\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\nimport Rails from \"@rails/ujs\"\nimport Turbolinks from \"turbolinks\"\nimport * as ActiveStorage from \"@rails/activestorage\"\nimport \"channels\"\n\nrequire(\"bootstrap\");\nimport '@fortawesome/fontawesome-free/js/all';\n\nimport \"packs/post_content_count\"\n\n//swiperの使用\nrequire(\"swiper/swiper-bundle.esm\");\nimport \"packs/swiper\" //自分で作成したpacks/swiper.jsを読み込む\n\nRails.start()\nTurbolinks.start()\nActiveStorage.start()\n","window.addEventListener(\"turbolinks:load\", () => {\n const input = document.querySelector(\"#post-content-input\");\n const counter = document.querySelector(\"#post-content-count\");\n\n if (!!input) {\n input.addEventListener(\"input\", (e) => {\n const inputValue = e.target.value\n const count = [...inputValue].length\n counter.textContent = count;\n\n const isRed = counter.classList.contains(\"color-red\");\n if (count > 300 && !isRed) {\n counter.classList.add(\"color-red\");\n } else if (count <= 300 && isRed) {\n counter.classList.remove(\"color-red\");\n }\n });\n }\n});\n","/* --------------------------------------- */\n/* スライド */\n/* --------------------------------------- */\n\nimport Swiper, { Navigation, Pagination } from 'swiper'\n// import 'swiper/css'\ndocument.addEventListener(\"DOMContentLoaded\", function () { //発火タイミングを指定\n // スライドの数を決定するためにウィンドウ幅を取得する\n var wide = window.innerWidth;\n var slidercount;\n if (wide > 767) {\n slidercount = 3;\n } else {\n slidercount = 1;\n }\n var mySwiper_member = new Swiper(\".slider\", {\n // 詳細設定\n loop: true, // 連続でスライド可能にするか。\n speed: 800, // スライドが切り替わる時間(ミリ秒)。\n slidesPerView: slidercount, // スライドを一度に何枚表示するか\n spaceBetween: 0, // スライド間の余白(ピクセル)\n direction: \"horizontal\", // effectがslideの場合のスライドする方向。 'horizontal'(水平) or 'vertical'(垂直)。\n effect: \"slide\", // \"slide\" or \"fade\"(フェード) or \"cube\"(キューブ回転) or \"coverflow\"(カバーフロー) or \"flip\"(平面回転)。\n\n // スライダーの自動再生\n // autoplay: trueのみなら既定値での自動再生\n // autoplay: false,\n autoplay: {\n delay: 2000, // スライドが切り替わるまでの表示時間(ミリ秒)\n stopOnLast: false, // 最後のスライドまで表示されたら自動再生を中止するか\n disableOnInteraction: false, // ユーザーのスワイプ操作を検出したら自動再生を中止するか\n },\n\n // ページネーションを有効化\n pagination: {\n el: \".slider__pagination\",\n type: \"bullets\",\n clickable: true,\n },\n\n // ナビゲーションを有効化\n navigation: {\n nextEl: \".slider__button-next\",\n prevEl: \".slider__button-prev\",\n },\n });\n});\n"],"mappings":";;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;ACRA;AACA;AAEA;AACA;AAAA;;;;;;;;;;;;ACJA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AAAA;AAEA;AACA;AAEA;AACA;AAAA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;ACrBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAAA;AACA;AAAA;AAEA;AACA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;AClBA;AAAA;AAAA;AACA;AAAA;AACA;AAAA;AAEA;AACA;AACA;AAAA;AACA;AACA;AACA;AACA;AAAA;AACA;AACA;AACA;AACA;AACA;AAAA;AACA;AACA;AAAA;AACA;AAAA;AACA;AAAA;AACA;AAAA;AACA;AAAA;AACA;AAAA;AAEA;AACA;AACA;AACA;AACA;AAAA;AACA;AAAA;AACA;AACA;AAJA;AAMA;AACA;AACA;AACA;AACA;AAHA;AAMA;AACA;AACA;AACA;AAFA;AA1BA;AA+BA;;;;A","sourceRoot":""}