{"id":657,"date":"2019-07-20T09:59:51","date_gmt":"2019-07-20T09:59:51","guid":{"rendered":"https:\/\/coru2.com\/blog\/?p=657"},"modified":"2019-07-20T09:59:54","modified_gmt":"2019-07-20T09:59:54","slug":"%e3%82%b9%e3%83%a9%e3%82%a4%e3%83%89slick-js-%e3%82%92-%e3%83%a2%e3%83%bc%e3%83%80%e3%83%abbootstrap%e3%81%ab%e8%a8%ad%e7%bd%ae%e3%81%99%e3%82%8b%e6%99%82%e3%81%ab%e3%83%8f%e3%83%9e%e3%81%a3","status":"publish","type":"post","link":"https:\/\/coru2.com\/blog\/archives\/657","title":{"rendered":"\u30b9\u30e9\u30a4\u30c9(Slick.js) \u3092 \u30e2\u30fc\u30c0\u30eb(Bootstrap)\u306b\u8a2d\u7f6e\u3059\u308b\u6642\u306b\u30cf\u30de\u3063\u305f\u8a71\u3002"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Carousel(Slick.js) in Modal Window(Bootstrap)<\/h2>\n\n\n\n<p>\u4ed5\u4e8b\u3067\u30e2\u30fc\u30c0\u30eb\u30a6\u30a4\u30f3\u30c9\u30a6\u4f7f\u3046\u5834\u9762\u304c\u3042\u3063\u305f\u306e\u3067<\/p>\n\n\n\n<p>\u300c\u305b\u3084\uff01Bootstrap\u3067\u5b9f\u88c5\u3057\u305f\u308d\uff01\u300d<\/p>\n\n\n\n<p>\u305d\u3093\u306a\u611f\u3058\u3067\u5b9f\u88c5\u3057\u3066\u3001\u5f8c\u3067\u6c17\u3065\u3044\u305f<\/p>\n\n\n\n<p>\u300c\u3053\u308c\u3001\u30e2\u30fc\u30c0\u30eb\u30a6\u30a4\u30f3\u30c9\u30a6\u306e\u4e2d\u306b\u30b9\u30e9\u30a4\u30c9\u30b7\u30e7\u30fc\u3042\u308b\u3084\u3093\u2026\u300d<\/p>\n\n\n\n<p>\u30c7\u30b6\u30a4\u30f3\u3061\u3083\u3093\u3068\u898b\u3066\u306a\u304b\u3063\u305f\u306e\u304c\u60aa\u3044\u3093\u3060\u3051\u3069\u3001\u305d\u3082\u305d\u3082\u30e2\u30fc\u30c0\u30eb\u306e\u4e2d\u306b\uff08\u4ee5\u4e0b\u7565<\/p>\n\n\n\n<p>\u306a\u3093\u3068\u306a\u304fBootstrap\u5185\u306b\u3042\u308bcarousel.js\u3067\u5b9f\u88c5\u3067\u304d\u305d\u3046\u306a\u6c17\u306f\u3057\u3066\u305f\u306e\u3067\u3059\u304c\u3001\u5f8c\u304b\u3089\u8272\u3005\u6a5f\u80fd\u8ffd\u52a0\u3059\u308b\u969b\u5384\u4ecb\u305d\u3046\u3060\u3063\u305f\u306e\u3067\u3001<\/p>\n\n\n\n<p>\u300cModal\u306bSlick.js\u5165\u308c\u305f\u308d\uff01\u300d<\/p>\n\n\n\n<p>\u305d\u3093\u306a\u611f\u3058\u306b\u5165\u308c\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<!--more-->\n\n\n\n<h2 class=\"wp-block-heading\">\u52d5\u304b\u306a\u3044<\/h2>\n\n\n\n<p>\u4e88\u611f\u306f\u3057\u3066\u307e\u3057\u305f\u304c\u3001\u52d5\u304d\u307e\u305b\u3093\u3002<\/p>\n\n\n\n<p>\u305f\u3076\u3093\u3001\u9045\u5ef6\u5b9f\u884c\u3068\u30e2\u30fc\u30c0\u30eb\u5b9f\u884c\u6642\u306e\u30a4\u30d9\u30f3\u30c8\u306b\u95a2\u9023\u3057\u305f\u52d5\u304d\u3092\u3069\u3046\u306b\u304b\u3057\u306a\u3044\u3068\u7121\u7406\u305d\u3046\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u7d50\u8ad6\uff1a\u3067\u304d\u305f<\/h2>\n\n\n\n<p>\u74b0\u5883\u306f\u3053\u3093\u306a\u611f\u3058\u306b\u3057\u3066\u307e\u3059<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>jQuery 3.4.1<\/li><li>bootstrap 4.3.1<\/li><li>slick.js 1.8.0<\/li><\/ul>\n\n\n\n<p>Javascript<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/WordPress\u306e\u5834\u5408\u306f$(function(){\u3000\u2192\u3000jQuery(function($){\u3000\u306b\u5909\u66f4\n&lt;script>\n  $(function () {\n    \/\/\u30e2\u30fc\u30c0\u30eb\u304c\u5b9f\u884c\u3055\u308c\u305f\u5f8c\u306e\u30a4\u30d9\u30f3\u30c8\u3092\u6307\u5b9a\n    $('#exampleModal').on('shown.bs.modal', function (event) {\n      \/\/slide\u90e8\u5206\u3092\u9045\u5ef6\u8868\u793a\n      $('.slick-wrap').animate({opacity:1},300);\n      \/\/slick\u3055\u305b\u308b\n      $('.slide').slick();\n    });\n  });\n&lt;\/script><\/code><\/pre>\n\n\n\n<p>HTML<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;!-- Button trigger modal -->\n&lt;button type=\"button\" class=\"btn btn-primary\" data-toggle=\"modal\" data-target=\"#exampleModal\">\n  Carousel(Slick.js) in Modal Window(Bootstrap)\n&lt;\/button>\n\n&lt;!-- Modal -->\n&lt;div class=\"modal fade\" id=\"exampleModal\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"exampleModalLabel\" aria-hidden=\"true\">\n  &lt;div class=\"modal-dialog\" role=\"document\">\n    &lt;div class=\"modal-content\">\n      &lt;div class=\"modal-header\">\n        &lt;h5 class=\"modal-title\" id=\"exampleModalLabel\">Modal title&lt;\/h5>\n        &lt;button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          &lt;span aria-hidden=\"true\">\u00d7&lt;\/span>\n        &lt;\/button>\n      &lt;\/div>\n      &lt;div class=\"modal-body\">\n          &lt;div class=\"modal-body\">\n            &lt;!--\u6700\u521d\u306f\u975e\u8868\u793a\u306b\u3057\u3066\u304a\u304f-->\n            &lt;div class=\"slick-wrap\" style=\"opacity:0;\">\n                &lt;ul class=\"slide single-item\">\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_01.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_02.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_03.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_04.jpg\" alt=\"\">&lt;\/li>\n                &lt;\/ul>\n                &lt;ul class=\"slide single-item\">\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_02.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_01.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_03.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_04.jpg\" alt=\"\">&lt;\/li>\n                &lt;\/ul>\n                &lt;ul class=\"slide single-item\">\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_03.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_02.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_01.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_04.jpg\" alt=\"\">&lt;\/li>\n                &lt;\/ul>\n                &lt;ul class=\"slide single-item\">\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_04.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_03.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_02.jpg\" alt=\"\">&lt;\/li>\n                  &lt;li>&lt;img src=\"http:\/\/coru2.com\/img\/timg\/img_01.jpg\" alt=\"\">&lt;\/li>\n                &lt;\/ul>\n            &lt;\/div>\n          &lt;\/div>\n      &lt;\/div>\n      &lt;div class=\"modal-footer\">\n        &lt;button type=\"button\" class=\"btn btn-secondary\" data-dismiss=\"modal\">Close&lt;\/button>\n        &lt;button type=\"button\" class=\"btn btn-primary\">Save changes&lt;\/button>\n      &lt;\/div>\n    &lt;\/div>\n  &lt;\/div>\n&lt;\/div><\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">DEMO<\/h2>\n\n\n\n<p>\u30c7\u30e2\u30da\u30fc\u30b8\u306f\u3053\u3061\u3089\u3002<\/p>\n\n\n\n<div class=\"wp-block-button\"><a class=\"wp-block-button__link\" href=\"http:\/\/coru2.com\/bootstrap_and_slickjs\/\">DEMO<\/a><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Carousel(Slick.js) in Modal Window(Bootstrap) \u4ed5\u4e8b\u3067\u30e2\u30fc\u30c0\u30eb\u30a6\u30a4\u30f3\u30c9\u30a6\u4f7f\u3046\u5834\u9762\u304c\u3042\u3063\u305f\u306e\u3067 \u300c\u305b\u3084\uff01Bootstrap\u3067\u5b9f\u88c5\u3057\u305f\u308d\uff01\u300d \u305d\u3093\u306a\u611f\u3058\u3067\u5b9f\u88c5\u3057\u3066\u3001\u5f8c\u3067\u6c17\u3065\u3044\u305f \u300c [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":461,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":"","wp-seo-meta-description":"","wp-seo-meta-robots":[]},"categories":[58,59,7,54,2,55,56],"tags":[],"class_list":{"0":"post-657","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-slick-js","8":"category-bootstrap","9":"category-wordpress","10":"category-web","11":"category-2","12":"category-css","13":"category-javascript","14":"c-entry"},"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/posts\/657","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/comments?post=657"}],"version-history":[{"count":3,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/posts\/657\/revisions"}],"predecessor-version":[{"id":660,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/posts\/657\/revisions\/660"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/media\/461"}],"wp:attachment":[{"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/media?parent=657"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/categories?post=657"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/coru2.com\/blog\/wp-json\/wp\/v2\/tags?post=657"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}