From 2c048141abd48601b69385c1bf50b4e867eccd43 Mon Sep 17 00:00:00 2001 From: Jordan Han Date: Mon, 13 May 2019 17:13:11 +0800 Subject: [PATCH] testing coffeescript and jquery --- _assets/javascript/sequencer.coffee.liquid | 9 ++++++--- _config.yml | 2 ++ _posts/sketches/2019-05-13-sequencer.markdown | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/_assets/javascript/sequencer.coffee.liquid b/_assets/javascript/sequencer.coffee.liquid index 9ffc34f..5869970 100644 --- a/_assets/javascript/sequencer.coffee.liquid +++ b/_assets/javascript/sequencer.coffee.liquid @@ -1,8 +1,11 @@ #= require jquery-3.4.1.slim.js $(document).ready -> - console.log "JQuery running" + console.log "Document ready." -console.log "{{ site.title }}" audio = new Audio('{% asset CB.WAV %}') -audio.play(); \ No newline at end of file + +$(document).click -> + console.log "Test:" + $('.sequencer-button').each -> + console.log $(this).attr('row') + "," + $(this).attr('col') + ": " + $(this).prop('checked') diff --git a/_config.yml b/_config.yml index 3b319e0..76c7eed 100644 --- a/_config.yml +++ b/_config.yml @@ -83,6 +83,7 @@ assets: - assets/image - assets/img - assets/js + - assets/audio - _assets/styles - _assets/css - _assets/fonts @@ -93,6 +94,7 @@ assets: - _assets/image - _assets/img - _assets/js + - _assets/audio - styles - css - fonts diff --git a/_posts/sketches/2019-05-13-sequencer.markdown b/_posts/sketches/2019-05-13-sequencer.markdown index 885464e..4bd4aac 100644 --- a/_posts/sketches/2019-05-13-sequencer.markdown +++ b/_posts/sketches/2019-05-13-sequencer.markdown @@ -12,7 +12,7 @@ categories: toys
{% for y in (1..4) %} {% for x in (1..8) %} - + {% endfor %} {% endfor %}