Skip to content

Releases: pixelwatt/method

v1.1.6

20 Mar 01:17
Compare
Choose a tag to compare

This release adds Bootstrap Icons (v1.4.0) to the theme and provides ways to easily included embeded/inline svgs in frontend markup and CSS. This release also includes minor organization of the /inc folder.

Changes:

  • ( class-method-layout.php ) Added a new method, get_bs_icon_svg(), for retrieving an embeded svg element for a passed Bootstrap icon (if the icon exists). The method supports custom sizing, custom classes, and the inclusion of an aria-label attribute on the svg element, if needed.
  • ( inc/bootstrap-icons/ ) Added Bootstrap Icons v1.4.0.
  • ( package.json / gulpfile.js ) Added a new assets gulp task and dependencies. This task uses gulp-postcss and postcss-assets to check newly-compiled css files for svg paths pointed to specific directiories, and converts them into inline SVGs if wrapped in inline(…). the serve and watch tasks now run this task after completing the styles task.
  • ( inc/ ) Organized files in the root of inc/ into folders and removed a legacy bootstrap.bundle file. Paths have been updated in functions.php and gulpfile.js

v1.1.5

19 Mar 07:22
Compare
Choose a tag to compare

Fixes:

  • ( class-method-layout.php ) Added the missing $class argument to the array_to_ul() method.
  • ( class-method-layout.php ) Fixed a bug in the inject_modal() and inject_bs_modal() methods in which an extra button closing tag was being added into the modal header.
  • ( class-method-layout.php ) Reversed the order of the $even_text and $odd_text arguments for the odd_or_even() method.

v1.1.4

18 Mar 23:38
Compare
Choose a tag to compare

This release includes bug fixes and additions for the layout class.

Fixes:

  • ( class-method-layout.php ) Revised the inject_modal() method to use Bootstrap 5 markup for the close button by default. A new argument can be passed as false to use Bootstrap 4 markup if needed.
  • ( class-method-layout.php ) Fixed a bug with the inject_modal() method, in which custom CSS classes passed to the method were ignored.

Additions:

  • ( class-method-layout.php ) Added a new method, format_headline(), which escapes html in a string, then runs the string through the format_tags() method.
  • ( class-method-layout.php ) Added a new method to replace the existing inject_modal() method. This new method, inject_bs_modal(), accepts arguments as an array and uses WordPress' standardized method to merge passed args with an array of defaults. This new method also adds support for using the small and extra-large modal sizes, and includes an argument for hiding the modal title. The inject_modal() modal will continue to be included for backwards compatability.
  • ( class-method-layout.php ) Added a new method, get_bg_inline_style(), for conditionally building an inline style tag for a background image, based on whether the passed attachment ID evaluates as true.
  • ( class-method-layout.php ) Added a new method, odd_or_even(), which returns a distinct value based on whether a passed number is odd or even. 'odd' or 'even' is returned by default, but custom values can be passed to the method if needed.

v1.1.3

01 Mar 18:03
Compare
Choose a tag to compare

This release includes several new methods and enhancements for the Method_Layout class.

Changes:

  • ( class-method-layout.php ) Added a new argument to the array_to_p() method for keeping a provided seperator visible.
  • ( class-method-layout.php ) Added a new method, get_headline_from_option(), for building a headline from a retrieved theme option.
  • ( class-method-layout.php ) Added a new method, get_content_from_option(), for building filtered content from a retrieved theme option.
  • ( class-method-layout.php ) Added a new method, get_loaded_content(), for building filtered content from a loaded meta key.
  • ( class-method-layout.php ) Added a new method, get_content(), for building filtered content from a meta key belonging to the current post ID.
  • ( class-method-layout.php ) Reformated the file to be more readable and structured.

v1.1.2

01 Mar 11:30
Compare
Choose a tag to compare

This release implements bug fixes and enhancements to the Method_Layout class.

Changes:

  • ( class-method-layout.php ) Reformatted the file to better fall in line with the WordPress Core coding standard.
  • ( class-method-layout.php ) Fixed a bug with the output of the inject_modal() method. The correct CSS ID is now applied to the modal headline.
  • ( class-method-layout.php ) Output for the array_to_ul() and array_to_p() methods is now passed through the format_tags() method.
  • ( class-method-layout.php ) A class can now be added to the ul tag generated by the array_to_ul() method.
  • ( class-method-layout.php ) A visually-hidden seperator can now be included before each line break in the output of the array_to_p() method.
  • ( class-method-layout.php ) Classes for the [br] and [mbr] format tags have been modified to be more reliable.

v1.1.1

26 Feb 21:35
Compare
Choose a tag to compare

Changes:

  • Fixed an issue with the core layout class that caused a fatal error (attributes were private and are now protected)
  • Updated Bootstrap to v5.0.0-beta2 and moved variable customization into the theme.scss file. This makes it possible to upgrade Bootstrap without having to worry about any overrides being lost.
  • Bootstrap js and scss files can now be found under inc/bootstrap
  • Renamed the theme layout class.

v1.1.0

19 Feb 15:02
Compare
Choose a tag to compare

This release implements a new abstract layout class, called Method_Layout, which the theme layout class now extends. This makes it possible to upgrade the core layout class as new versions are released, as the utility functions are now seperated from theme-specific code. Going forward, releases will include the option to download only the layout class.

Changes:

  • ( new file: class-method-layout.php ) Added the new parent layout class
  • ( functions.php ) Fixed a reference to an undeclared variable in the check_key() function.
  • ( functions.php ) Rewrote the theme layout class to extend the new Method_Layout class.