Skip to content

Releases: Log1x/sage-directives

v1.0.5

13 Feb 06:51
Compare
Choose a tag to compare

Changelog

Bug Fixes

  • Change is_number() to is_numeric() (oops)
  • Fix @published typo on README

v1.0.4

12 Feb 05:42
Compare
Choose a tag to compare

Changelog

Features

  • Added 12+ new helper directives: @istrue, @isfalse, @isnull, @isnotnull, @instanceof, @typeof, @repeat, @style, @script, @js, @inline, @fa
  • Added 6 new WordPress directives: @author, @authorurl, @published, @modified, @wpautop, @wpautokp
  • Refactored @posts allowing it to accept post ID's, WP_Post instances, or an array with a combination of the two (#8)
  • Refactored source code DocBlocks and formatting of directives
  • Improved formatting and examples for documentation

Bug Fixes

  • Fix missing closing parenthesis in fields directive (#7)
  • Added missing parameters to allow passing an array key to @isfield, @issub, and @isoption

Breaking Change

  • @condition has been replaced with @istrue / @isfalse

v1.0.3

31 Jan 01:28
Compare
Choose a tag to compare

Changelog

Bug Fixes

  • Add a function_exists() check for add_action() to prevent issues in scenarios where WordPress core is not loaded (e.g. Composer).

v1.0.2

08 Dec 01:28
102466e
Compare
Choose a tag to compare

Changelog

Features

  • Add usage documentation with examples.
  • Allow @posts to accept a custom WP_Query instance as a variable as well as return the main loop if $query is undefined and no variable is passed. (Thanks to @mmirus on #1)
  • Add @title, @content, and @excerpt WordPress directives.
  • Allow @option to accept a second parameter to return a value in an array.

Enhancements

  • Clean up @sub, @hassub, and @issub (were mistakenly accepting unusable param's originally from @field).
  • Clean up @condition syntax to be more uniform with the other directives.

Bug Fixes

  • Add missing @isoption directive.
  • Fix @options param typo.

v1.0.1

30 Oct 03:39
Compare
Choose a tag to compare

Changelogs

Enhancements

  • Rewrite utility methods making use of collect() and allowing easier argument splitting.
  • Refactor directives using new utility methods as well as allowing additional arguments to be passed for ACF directives such as post ID.
  • Make directive source code more readable.
  • Remove @getsub, @getfield, @dump, and @console.
  • Various miscellaneous clean up.

v1.0.0

18 Oct 03:45
Compare
Choose a tag to compare

Initial release