@heroku/ember-hk-components 0.17.0-beta.1 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,56 @@
1
+ ## 0.20.0 (2022-02-01)
2
+
3
+ #### :rocket: Enhancement
4
+ * [#188](https://github.com/heroku/ember-hk-components/pull/188) hk-slide-panel up the confirmable documentation runnable example ([@fivetanley](https://github.com/fivetanley))
5
+
6
+ #### :house: Internal
7
+ * [#205](https://github.com/heroku/ember-hk-components/pull/205) Update supported node versions to include 14 ([@eablack](https://github.com/eablack))
8
+ * [#199](https://github.com/heroku/ember-hk-components/pull/199) Update `app.json` to heroku-20 stack ([@cafreeman](https://github.com/cafreeman))
9
+
10
+ #### Committers: 3
11
+ - Chris Freeman ([@cafreeman](https://github.com/cafreeman))
12
+ - Eric ([@eablack](https://github.com/eablack))
13
+ - Stanley Stuart ([@fivetanley](https://github.com/fivetanley))
14
+
15
+ ## 0.19.0 (2020-10-06)
16
+
17
+ #### :rocket: Enhancement
18
+ * [#180](https://github.com/heroku/ember-hk-components/pull/180) Associate validation error status with hk-form-group ([@brettgoulder](https://github.com/brettgoulder))
19
+ * [#181](https://github.com/heroku/ember-hk-components/pull/181) Utilize Dashboard test devmode and UI ([@brettgoulder](https://github.com/brettgoulder))
20
+
21
+ #### Committers: 1
22
+ - Brett Goulder ([@brettgoulder](https://github.com/brettgoulder))
23
+
24
+ ## 0.18.0 (2020-08-10)
25
+
26
+ #### :bug: Bug Fix
27
+ * [#177](https://github.com/heroku/ember-hk-components/pull/177) fix: Malibu icon upgrade + fix accessibility violations ([@fivetanley](https://github.com/fivetanley))
28
+
29
+ #### :memo: Documentation
30
+ * [#172](https://github.com/heroku/ember-hk-components/pull/172) Update release documentation ([@samarao](https://github.com/samarao))
31
+
32
+ #### Committers: 2
33
+ - Sama ([@samarao](https://github.com/samarao))
34
+ - Stanley Stuart ([@fivetanley](https://github.com/fivetanley))
35
+
36
+ #### :memo: Documentation
37
+ * [#172](https://github.com/heroku/ember-hk-components/pull/172) Update release documentation ([@samarao](https://github.com/samarao))
38
+
39
+ #### Committers: 2
40
+ - Sama ([@samarao](https://github.com/samarao))
41
+ - Stanley Stuart ([@fivetanley](https://github.com/fivetanley))
42
+
43
+ ## 0.17.0 (2020-05-27)
44
+
45
+ #### :rocket: Enhancement
46
+ * [#170](https://github.com/heroku/ember-hk-components/pull/170) Set the trap focus default to true for hk-slide-panel ([@samarao](https://github.com/samarao))
47
+
48
+ #### :house: Internal
49
+ * [#169](https://github.com/heroku/ember-hk-components/pull/169) Bump jquery from 3.4.1 to 3.5.0 ([@dependabot[bot]](https://github.com/apps/dependabot))
50
+
51
+ #### Committers: 1
52
+ - Sama ([@samarao](https://github.com/samarao))
53
+
1
54
  ## 0.16.0 (2020-04-16)
2
55
 
3
56
  #### :house: Internal
package/README.md CHANGED
@@ -77,11 +77,10 @@ This library does its best to follow the principles of [Semantic Versioning](htt
77
77
 
78
78
  #### Changelog
79
79
 
80
- This project's changelog is generated using `lerna-changelog`. You can find instructions on how to setup your local environment for this in [the project's Readme](https://github.com/lerna/lerna-changelog#usage). Note that the Personal access token you use must be SSO-enabled for this to work.
80
+ This project's changelog is generated using `lerna-changelog`. You can find instructions on how to setup your local environment for this in [the project's Readme](https://github.com/lerna/lerna-changelog#github-token). Note that the Personal access token you use must be [SSO-enabled](https://help.github.com/en/github/authenticating-to-github/authorizing-a-personal-access-token-for-use-with-saml-single-sign-on) for this to work.
81
81
 
82
82
  `lerna-changelog` works off a system of labels defined in [this project's package.json](https://github.com/heroku/ember-hk-components/blob/9bdcf240e2294b48cac2e4f99ac5b706b7b17214/package.json#L61-L70). Pull requests will be collated into the changelog based on which label has been applied to them.
83
83
 
84
-
85
84
  #### Making a New Release
86
85
 
87
86
  Once you are ready to make a new release follow these steps:
@@ -93,6 +92,8 @@ Once you are ready to make a new release follow these steps:
93
92
  * Copy the output of that command into Changelog.md
94
93
  * Commit your changes and open a PR
95
94
 
96
- Once the PR is approved and merged you can then tag and publish your new version to npm with the command `npm publish` 🎉
95
+ Once the PR is approved and merged you can then tag your new version by running `git tag x.x.x` where `x.x.x` is the new version number. Push your tag to GitHub using `git push origin --tags`.
96
+
97
+ Publish your new version to npm with the command `npm publish` 🎉
97
98
 
98
99
  _Note that you must have publish access to the @heroku npm organization to successfully publish_
@@ -4,9 +4,12 @@ import { computed } from '@ember/object';
4
4
 
5
5
  export default FieldValidations.extend({
6
6
  layout,
7
- fieldType: 'hk-input',
7
+ fieldType: "hk-input",
8
8
  groupId: computed(function() {
9
- return `hk-form-field-${this.get('elementId')}`;
9
+ return `hk-form-field-${this.get("elementId")}`;
10
+ }),
11
+ errorsListId: computed("groupId", function() {
12
+ return `${this.groupId}-errors-list`;
10
13
  }),
11
14
  isRequired: false
12
15
  });
@@ -6,6 +6,7 @@ import layout from '@heroku/ember-hk-components/templates/components/hk-input-wi
6
6
  export default Component.extend({
7
7
  layout,
8
8
  tagName: '',
9
+ supportsDataTestProperties: true,
9
10
  isFieldChanged: false,
10
11
  inputValue: oneWay('value'),
11
12
  isFieldNotEmpty: notEmpty('value'),
@@ -2,6 +2,7 @@ import TextField from '@ember/component/text-field';
2
2
  import { run } from '@ember/runloop';
3
3
 
4
4
  export default TextField.extend({
5
+ attributeBindings: ['aria-describedby'],
5
6
  classNameBindings: ['isValid:b--light-green', 'isValid:hk-focus-ring--green', 'isInvalid:b--light-red', 'isInvalid:hk-focus-ring--red', 'disabled:hk-input--disabled', 'readonly:hk-input--read-only'],
6
7
  classNames: ['hk-input'],
7
8
 
@@ -53,7 +53,7 @@ export default Component.extend({
53
53
 
54
54
  clickOverlayToClose: true,
55
55
 
56
- trapFocus: false,
56
+ trapFocus: true,
57
57
 
58
58
  isTest: computed(function() {
59
59
  const config = getOwner(this).resolveRegistration('config:environment');
@@ -1,9 +1,11 @@
1
1
  {{#if isPending}}
2
- {{malibu-icon name="loading-16" size="16" iconClass='fill-gray v-mid'}}
2
+ <MalibuIcon @name="loading-16" @size={{16}} @iconClass='fill-gray v-mid' @title="Loading" />
3
3
  {{else}}
4
4
  {{#if hasBlock}}
5
5
  {{yield}}
6
6
  {{else}}
7
+ {{!-- TODO: remove this... when we figure out when apps stop putting HTML here... --}}
8
+ {{!-- template-lint-disable no-triple-curlies --}}
7
9
  {{{text}}}
8
10
  {{/if}}
9
11
  {{/if}}
@@ -1,6 +1,6 @@
1
1
  {{yield (hash
2
2
  value=value
3
3
  label=(component 'hk-label' for=groupId isRequired=isRequired data-test-target=(concat 'form-group-label-' property))
4
- field=(component fieldType id=groupId value=value isValid=isValid isInvalid=isInvalid isValidating=isValidating data-test-target=(concat 'form-group-field-' property))
5
- errorsList=(component 'hk-validation-errors-list' validationErrors=validationErrors property=property)
6
- )}}
4
+ field=(component fieldType id=groupId value=value isValid=isValid isInvalid=isInvalid isValidating=isValidating aria-describedby=(concat groupId '-errors-list') data-test-target=(concat 'form-group-field-' property))
5
+ errorsList=(component 'hk-validation-errors-list' validationErrors=validationErrors property=property errorsListId=errorsListId)
6
+ )}}
@@ -11,20 +11,22 @@
11
11
  disabled=disabled
12
12
  maxlength=maxlength
13
13
  placeholder=placeholder
14
- readonly=readonly}}
14
+ readonly=readonly
15
+ aria-describedby=errorsListId
16
+ }}
15
17
 
16
18
  {{#if isShowingStatus}}
17
19
  {{#if isValidating}}
18
20
  <div class="flex items-center bg-light-silver br1 br--right bt br bb b--light-gray ph2" data-test-target="loading-icon">
19
- {{malibu-icon name="loading-16" iconClass="malibu-fill-gradient-dark-gray" size="16"}}
21
+ <MalibuIcon @name="loading-16" @iconClass="malibu-fill-gradient-dark-gray" @size={{16}} @title="Loading" />
20
22
  </div>
21
23
  {{else if isValid}}
22
24
  <div class="flex items-center bg-lightest-green br1 br--right bt br bb b--light-green ph2" data-test-target="valid-icon">
23
- {{malibu-icon name="success-badge-16" iconClass="malibu-fill-gradient-green" size="16"}}
25
+ <MalibuIcon @name="success-badge-16" @iconClass="malibu-fill-gradient-green" @size={{16}} @title="{{name}} is valid" />
24
26
  </div>
25
27
  {{else}}
26
28
  <div class="flex items-center bg-lightest-red br1 br--right bt br bb b--light-red ph2" data-test-target="invalid-icon">
27
- {{malibu-icon name="failure-badge-16" iconClass="malibu-fill-gradient-red" size="16"}}
29
+ <MalibuIcon @name="failure-badge-16" @iconClass="malibu-fill-gradient-red" @size={{16}} @title="{{name}} is invalid" />
28
30
  </div>
29
31
  {{/if}}
30
32
  {{/if}}
@@ -1,2 +1,2 @@
1
- {{malibu-icon name='search-16' size='16' iconClass='fill-gray absolute ml2 mt1 nudge-down--3' role='presentation' title=''}}
1
+ <MalibuIcon @name='search-16' @size={{16}} @iconClass='fill-gray absolute ml2 mt1 nudge-down--3' aria-hidden="true" />
2
2
  {{input id=inputId value=value placeholder=placeholder class='hk-search-input w-100' autocapitalize='off' autocorrect='off' autocomplete='off' spellcheck='false'}}
@@ -1,6 +1,7 @@
1
1
  <div
2
2
  class="hk-slide-panel-breakout-overlay"
3
3
  data-test-target="slide-panel-breakout-overlay"
4
+ {{!-- template-lint-disable no-invalid-interactive --}}
4
5
  onclick={{action onClickOverlay (action dismiss)}}
5
6
  ></div>
6
7
 
@@ -13,5 +13,5 @@
13
13
  data-test-target="slide-panel-dismiss"
14
14
  aria-label={{this.shownDismissLabel}}
15
15
  >
16
- {{malibu-icon name="delete-16" iconClass="fill-gray" size="16" title=this.shownDismissLabel}}
16
+ <MalibuIcon @name="delete-16" @iconClass="fill-gray" @size={{16}} @title={{this.shownDismissLabel}} />
17
17
  </button>
@@ -1,7 +1,8 @@
1
- {{#if hasValidationErrors}}
2
- <ul class="list pl0 red mv2 f5 normal lh-copy" data-test-target={{concat 'validation-errors-' property}}>
3
- {{#each validationErrorMessages as |message|}}
4
- <li>{{message}}</li>
5
- {{/each}}
6
- </ul>
7
- {{/if}}
1
+ <ul
2
+ class="list pl0 red mv2 f5 normal lh-copy {{unless hasValidationErrors 'clip'}}"
3
+ id={{errorsListId}}
4
+ data-test-target={{concat 'validation-errors-' property}}>
5
+ {{#each validationErrorMessages as |message|}}
6
+ <li>{{message}}</li>
7
+ {{/each}}
8
+ </ul>
package/app.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "ember-hk-components",
3
3
  "description": "Ember Hk Components",
4
+ "stack": "heroku-20",
4
5
  "buildpacks": [
5
6
  { "url": "heroku/nodejs" },
6
7
  { "url": "https://github.com/heroku/heroku-buildpack-ember-cli" },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heroku/ember-hk-components",
3
- "version": "0.17.0-beta.1",
3
+ "version": "0.20.0",
4
4
  "description": "Ember HK Components",
5
5
  "keywords": [
6
6
  "ember-addon"
@@ -13,57 +13,66 @@
13
13
  },
14
14
  "scripts": {
15
15
  "build": "ember build",
16
+ "lint:hbs": "ember-template-lint .",
16
17
  "lint:js": "eslint .",
18
+ "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*",
19
+ "lint:hbs:fix": "ember-template-lint . --fix",
17
20
  "start": "ember server",
18
- "test": "ember test",
19
- "changelog": "lerna-changelog",
20
- "test:all": "ember try:each"
21
+ "test": "npm-run-all lint:* test:ember",
22
+ "test:ember": "ember test",
23
+ "test:ember-compatibility": "ember try:each",
24
+ "changelog": "lerna-changelog"
21
25
  },
22
26
  "dependencies": {
23
- "@heroku/ember-malibu-icon": "^1.3.0",
27
+ "@heroku/ember-malibu-icon": "^1.6.0",
28
+ "ember-auto-import": "^1.12.1",
24
29
  "body-scroll-lock": "^2.6.1",
25
- "ember-auto-import": "^1.5.2",
26
30
  "ember-changeset": "^1.4.0",
27
31
  "ember-changeset-validations": "^1.2.8",
28
- "ember-cli-babel": "^7.7.3",
29
- "ember-cli-htmlbars": "^5.1.2",
32
+ "ember-cli-babel": "^7.21.0",
33
+ "ember-cli-htmlbars": "^5.2.0",
30
34
  "ember-focus-trap": "^0.3.2",
31
35
  "ember-wormhole": "^0.5.5",
32
36
  "emberx-select": "^4.0.0-beta.2"
33
37
  },
34
38
  "devDependencies": {
35
- "@ember/optional-features": "^0.7.0",
39
+ "@ember/optional-features": "^1.3.0",
40
+ "@glimmer/component": "^1.0.1",
41
+ "@glimmer/tracking": "^1.0.0",
42
+ "babel-eslint": "^10.1.0",
36
43
  "broccoli-asset-rev": "^3.0.0",
37
44
  "chai": "^4.2.0",
38
45
  "ember-a11y-testing": "^2.0.0",
39
- "ember-cli": "~3.12.0",
46
+ "ember-cli": "~3.20.2",
40
47
  "ember-cli-chai": "^0.5.0",
41
- "ember-cli-dependency-checker": "^3.1.0",
42
- "ember-cli-eslint": "^5.1.0",
48
+ "ember-cli-dependency-checker": "^3.2.0",
43
49
  "ember-cli-eyeglass": "^6.4.2",
44
- "ember-cli-inject-live-reload": "^1.8.2",
50
+ "ember-cli-inject-live-reload": "^2.0.2",
45
51
  "ember-cli-sri": "^2.1.1",
46
- "ember-cli-uglify": "^2.1.0",
52
+ "ember-cli-uglify": "^3.0.0",
47
53
  "ember-disable-prototype-extensions": "^1.1.3",
48
- "ember-export-application-global": "^2.0.0",
54
+ "ember-export-application-global": "^2.0.1",
49
55
  "ember-freestyle": "^0.11.9",
50
- "ember-load-initializers": "^2.0.0",
56
+ "ember-load-initializers": "^2.1.1",
51
57
  "ember-maybe-import-regenerator": "^0.1.6",
52
58
  "ember-mocha": "^0.16.2",
53
- "ember-resolver": "^5.0.1",
59
+ "ember-resolver": "^8.0.0",
54
60
  "ember-sinon": "^2.1.0",
55
- "ember-source": "~3.12.0",
56
- "ember-source-channel-url": "^1.1.0",
61
+ "ember-source": "~3.20.7",
62
+ "ember-source-channel-url": "^2.0.1",
63
+ "ember-template-lint": "^2.10.0",
57
64
  "ember-test-selectors": "^0.3.6",
58
- "ember-try": "^1.0.0",
59
- "eslint-plugin-ember": "^6.2.0",
60
- "eslint-plugin-node": "^9.0.1",
65
+ "ember-try": "^1.4.0",
66
+ "eslint": "^7.5.0",
67
+ "eslint-plugin-ember": "^8.9.1",
68
+ "eslint-plugin-node": "^11.1.0",
61
69
  "lerna-changelog": "^0.8.0",
62
70
  "loader.js": "^4.7.0",
71
+ "npm-run-all": "^4.1.5",
63
72
  "sinon-chai": "^3.2.0"
64
73
  },
65
74
  "engines": {
66
- "node": "8.* || 10.* || 12.*"
75
+ "node": "12.* || 14.*"
67
76
  },
68
77
  "changelog": {
69
78
  "repo": "heroku/ember-hk-components",
@@ -75,6 +84,9 @@
75
84
  "internal": ":house: Internal"
76
85
  }
77
86
  },
87
+ "ember": {
88
+ "edition": "octane"
89
+ },
78
90
  "ember-addon": {
79
91
  "configPath": "tests/dummy/config"
80
92
  }
@@ -1,6 +0,0 @@
1
- import Component from '@ember/component';
2
- import layout from '../templates/components/fix-snippets';
3
-
4
- export default Component.extend({
5
- layout
6
- });
@@ -1 +0,0 @@
1
- {{yield}}
@@ -1 +0,0 @@
1
- export { default } from '@heroku/ember-hk-components/components/fix-snippets';
package/jsconfig.json DELETED
@@ -1 +0,0 @@
1
- {"compilerOptions":{"target":"es6","experimentalDecorators":true},"exclude":["node_modules","bower_components","tmp","vendor",".git","dist"]}