Skip to content

Commit

Permalink
main and module fields in package.json + version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
tofsjonas committed Feb 14, 2024
1 parent de95594 commit 4803585
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 6 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [3.2.0] - 2024-02-14

### Added

- Introduced `main` and `module` fields in `package.json` to enhance compatibility with modern JavaScript tooling and environments.

## [3.1.0] - 2023-11-16

### Changed
Expand Down Expand Up @@ -118,6 +124,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

This CHANGELOG.md was generated with the assistance of [ChatGPT by OpenAI](https://www.openai.com/research/chatgpt).

[3.2.0]: https://github.com/tofsjonas/sortable/releases/tag/3.2.0
[3.1.0]: https://github.com/tofsjonas/sortable/releases/tag/3.1.0
[3.0.0]: https://github.com/tofsjonas/sortable/releases/tag/3.0.0
[2.4.0]: https://github.com/tofsjonas/sortable/releases/tag/2.4.0
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sortable-tablesort",
"version": "3.1.0",
"version": "3.2.0",
"description": "A tiny, Vanilla/Plain JavaScript table sorter",
"author": "Jonas Earendel",
"license": "Unlicense",
Expand All @@ -9,6 +9,8 @@
"type": "git",
"url": "git+https://github.com/tofsjonas/sortable.git"
},
"main": "sortable.min.js",
"module": "sortable.min.js",
"keywords": [
"sort",
"html",
Expand Down
5 changes: 4 additions & 1 deletion sortable.a11y.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var enhanceSortableAccessibility = function (tables) {
}
var aria_label = "Click to sort table by ".concat(header_text, " in ").concat(new_direction, " order");
element.setAttribute('aria-label', aria_label);
element.setAttribute('title', aria_label);
// element.setAttribute('title', aria_label) REMEMBER TO COMMENT OUT WHEN NOT TESTING!!
}
/**
* Handles keyboard events on table header cells and triggers a click event when the Enter key is pressed.
Expand All @@ -43,6 +43,9 @@ var enhanceSortableAccessibility = function (tables) {
// Iterate over each header cell in the table
headers.forEach(function (header) {
var element = header;
// Skip if the header cell already has a tabindex attribute
if (element.hasAttribute('tabindex'))
return;
var update = function () {
updateAriaLabel(element, default_direction);
};
Expand Down
4 changes: 2 additions & 2 deletions sortable.a11y.min.js

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

2 changes: 1 addition & 1 deletion sortable.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* sortable v3.1.0
* sortable v3.2.0
*
* https://www.npmjs.com/package/sortable-tablesort
* https://github.com/tofsjonas/sortable
Expand Down
2 changes: 1 addition & 1 deletion src/sortable.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* sortable v3.1.0
* sortable v3.2.0
*
* https://www.npmjs.com/package/sortable-tablesort
* https://github.com/tofsjonas/sortable
Expand Down

0 comments on commit 4803585

Please sign in to comment.