Skip to content

Commit

Permalink
bump to 2.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ChapelR committed Jan 23, 2020
1 parent a5eeb68 commit 141dfaa
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
8 changes: 8 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@
> [!NOTE]
> I'm going to start keeping a changelog for these macros because keeping track of them is becoming a nightmare. The overall version numbers are not really helpful for tracking what's happening on a macro-by-macro basis, but I'm trying to stick to major version bumps meaning breaking changes in any macro, or complete refactors of the whole collection, like what v2.0.0 was. Minor version updates indicate new macros have been added. Patch version updates means individual macro updates and bug fixes, or documentation, website, or demo updates.
### January 22, 2020 (v2.4.1)

- **[Update]** Fixed bug in `<<notify>>` CSS time parsing.
- **[Demo]** Typos and grammar fixes.
- **[Docs]** Changed defunct Q&A links to point to Twine category at IntFiction.org.
- **[Docs]** Typos and grammar fixes.
- **[Meta]** Added missing scripts to download utility.

### Jul 16, 2019 (v2.4.0)

- **[Update]** The `<<dialog>>` macro now accepts an `<<onopen>>` and `<<onclose>>` macro tag to set up handlers. These tags set up single-use event handlers for the dialog open and close events.
Expand Down
4 changes: 2 additions & 2 deletions docs/demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@
// end mouseover.min.js
/* twine-user-script #16: "notify.min.js" */
// notify.min.js, for SugarCube 2, by Chapel
;!function(){var n=/\d+m?s$/;function i(s,e,t){"string"==typeof s&&("number"!=typeof e&&(e=!1),$(document).trigger({type:":notify",message:s,delay:e,class:t||""}))}$(document.body).append("<div id='notify'></div>"),$(document).on(":notify",function(s){s.message&&"string"==typeof s.message&&(s.message.trim(),s.class?"string"==typeof s.class?s.class="open macro-notify "+s.class:Array.isArray(s.class)?s.class="open macro-notify "+s.class.join(" "):s.class="open macro-notify":s.class="open macro-notify",s.delay?("number"!=typeof s.delay&&(s.delay=Number(s.delay)),Number.isNaN(s.delay)&&(s.delay=2e3)):s.delay=2e3,$("#notify").empty().wiki(s.message).addClass(s.class),setTimeout(function(){$("#notify").removeClass()},s.delay))}),Macro.add("notify",{tags:null,handler:function(){var s=this.payload[0].contents,e=!1,t=!1;if(0<this.args.length){var a=n.test(this.args[0]);t="number"==typeof this.args[0]||a?(e=a?Util.fromCssTime(a):this.args[0],1<this.args.length&&this.args.slice(1).flatten()):this.args.flatten().join(" ")}i(s,e,t)}}),setup.notify=i}();
;!function(){var n=/\d+m?s$/;function i(s,e,t){"string"==typeof s&&("number"!=typeof e&&(e=!1),$(document).trigger({type:":notify",message:s,delay:e,class:t||""}))}$(document.body).append("<div id='notify'></div>"),$(document).on(":notify",function(s){s.message&&"string"==typeof s.message&&(s.message.trim(),s.class?"string"==typeof s.class?s.class="open macro-notify "+s.class:Array.isArray(s.class)?s.class="open macro-notify "+s.class.join(" "):s.class="open macro-notify":s.class="open macro-notify",s.delay?("number"!=typeof s.delay&&(s.delay=Number(s.delay)),Number.isNaN(s.delay)&&(s.delay=2e3)):s.delay=2e3,$("#notify").empty().wiki(s.message).addClass(s.class),setTimeout(function(){$("#notify").removeClass()},s.delay))}),Macro.add("notify",{tags:null,handler:function(){var s=this.payload[0].contents,e=!1,t=!1;if(0<this.args.length){var a=n.test(this.args[0]);t="number"==typeof this.args[0]||a?(e=a?Util.fromCssTime(this.args[0]):this.args[0],1<this.args.length&&this.args.slice(1).flatten()):this.args.flatten().join(" ")}i(s,e,t)}}),setup.notify=i}();
// end notify.min.js
/* twine-user-script #17: "operations.min.js" */
// operations.min.js, for SugarCube 2, by Chapel
Expand Down Expand Up @@ -785,7 +785,7 @@
The {{{&lt;&lt;notify&gt;&gt;}}} macro can be used to display a quick message to users. It&#39;s less discruptive that a dialog or alert, and ideal for something like a quick inventory or achievement update. You can click the link below to fire another notification in case you missed the first one. Note, however, that allowing users to activate these notifications like this is a bad idea; if they click too much, the animations will start to trip over each other.

&lt;&lt;link &#39;See a notification.&#39;&gt;&gt;
&lt;&lt;notify&gt;&gt;This is a notification!&lt;&lt;/notify&gt;&gt;
&lt;&lt;notify 5s&gt;&gt;This is a notification!&lt;&lt;/notify&gt;&gt;
&lt;&lt;/link&gt;&gt;

-----
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "custom-macros-for-sugarcube-2",
"version": "2.4.0",
"version": "2.4.1",
"description": "Collection of custom macros and systems for Twine/SugarCube2.",
"main": "build.js",
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion scripts/minified/notify.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 141dfaa

Please sign in to comment.