Skip to content

Commit 1388358

Browse files
Initial commit
0 parents  commit 1388358

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+20223
-0
lines changed

.eslintignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
helix-importer-ui

.eslintrc.js

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
module.exports = {
2+
root: true,
3+
extends: 'airbnb-base',
4+
env: {
5+
browser: true,
6+
},
7+
parser: '@babel/eslint-parser',
8+
parserOptions: {
9+
allowImportExportEverywhere: true,
10+
sourceType: 'module',
11+
requireConfigFile: false,
12+
},
13+
rules: {
14+
// allow reassigning param
15+
'no-param-reassign': [2, { props: false }],
16+
'linebreak-style': ['error', 'unix'],
17+
'import/extensions': ['error', {
18+
js: 'always',
19+
}],
20+
},
21+
};

.github/pull_request_template.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Please always provide the [GitHub issue(s)](../issues) your PR is for, as well as test URLs where your change can be observed (before and after):
2+
3+
Fix #<gh-issue-id>
4+
5+
Test URLs:
6+
- Before: https://main--{repo}--{owner}.hlx.live/
7+
- After: https://<branch>--{repo}--{owner}.hlx.live/
+53
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# This workflow will run upon repository creation and clean up
2+
# all files that are not strictly required to build an AEM Live project
3+
# but that we use to develop the project template. This includes this
4+
# particular workflow file.
5+
on:
6+
create:
7+
branches:
8+
- main
9+
jobs:
10+
cleanup:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
contents: write
14+
actions: write
15+
# only run if commit message is "Initial commit" on main branch
16+
if: ${{ github.ref == 'refs/heads/main' && github.event.head_commit.message == 'Initial commit' }}
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@v4
20+
- name: Use Node.js 18
21+
uses: actions/setup-node@v4
22+
with:
23+
node-version: 18
24+
- name: Uninstall dependencies
25+
run: |
26+
npm uninstall --save-dev semantic-release @semantic-release/git @semantic-release/changelog @semantic-release/exec
27+
- name: Remove Helper Files
28+
run: |
29+
rm -rf \
30+
.github/workflows/cleanup-on-create.yaml \
31+
.github/workflows/semantic-release.yaml \
32+
.releaserc.cjs \
33+
CHANGELOG.md
34+
35+
- name: Initialize README
36+
# replace {repo} and {owner} with the actual values
37+
run: |
38+
sed -i.bak "s/{repo}/$(basename ${{ github.repository }})/g" README.md
39+
sed -i.bak "s/{owner}/$(dirname ${{ github.repository }})/g" README.md
40+
- name: Initialize Pull Request Template
41+
run: |
42+
sed -i.bak "s/{repo}/$(basename ${{ github.repository }})/g" .github/pull_request_template.md
43+
sed -i.bak "s/{owner}/$(dirname ${{ github.repository }})/g" .github/pull_request_template.md
44+
45+
46+
# commit back to the repository
47+
- name: Commit changes
48+
run: |
49+
git config --local user.email "[email protected]"
50+
git config --local user.name "Helix Bot"
51+
git add .
52+
git commit -m "chore: cleanup repository template"
53+
git push

.github/workflows/run-tests.yaml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Linting
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v4
10+
- name: Use Node.js
11+
uses: actions/setup-node@v4
12+
with:
13+
node-version: '16' #required for npm 8 or later.
14+
- run: npm install
15+
- run: npm run lint
16+
env:
17+
CI: true
+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Generate a changelog with semantic-release
2+
# Skip if the commit message is "Initial commit"
3+
on:
4+
push:
5+
branches:
6+
- main
7+
jobs:
8+
semantic-release:
9+
if: ${{ ! contains(github.event.head_commit.message, 'Initial commit') }}
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v4
14+
- name: Setup Node.js
15+
uses: actions/setup-node@v4
16+
with:
17+
node-version: 18
18+
- name: Install dependencies
19+
run: npm ci
20+
- name: Run semantic-release
21+
env:
22+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23+
run: npm run semantic-release

.gitignore

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.hlx/*
2+
coverage/*
3+
logs/*
4+
node_modules/*
5+
6+
helix-importer-ui
7+
.DS_Store
8+
*.bak
9+
.idea

.hlxignore

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
.*
2+
*.md
3+
karma.config.js
4+
LICENSE
5+
package.json
6+
package-lock.json
7+
test/*

.releaserc.cjs

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = {
2+
plugins: [
3+
"@semantic-release/commit-analyzer",
4+
"@semantic-release/release-notes-generator",
5+
["@semantic-release/changelog", {
6+
"changelogFile": "CHANGELOG.md",
7+
}],
8+
["@semantic-release/npm", {
9+
"publish": false,
10+
}],
11+
["@semantic-release/git", {
12+
"assets": ["package.json", "CHANGELOG.md"],
13+
"message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"
14+
}],
15+
["@semantic-release/github", {}]
16+
],
17+
branches: ['main'],
18+
};

.renovaterc.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": ["config:recommended"]
3+
}

.stylelintrc.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": ["stylelint-config-standard"]
3+
}

404.html

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
<!DOCTYPE html>
2+
<html>
3+
4+
<head>
5+
<title>Page not found</title>
6+
<script type="text/javascript">
7+
window.isErrorPage = true;
8+
window.errorCode = '404';
9+
</script>
10+
<meta name="viewport" content="width=device-width, initial-scale=1">
11+
<meta property="og:title" content="Page not found">
12+
<script src="/scripts/scripts.js" type="module" crossorigin="use-credentials"></script>
13+
<script type="module">
14+
import { sampleRUM } from '/scripts/aem.js';
15+
16+
window.addEventListener('load', () => {
17+
if (document.referrer) {
18+
const { origin, pathname } = new URL(document.referrer);
19+
if (origin === window.location.origin) {
20+
const backBtn = document.createElement('a');
21+
backBtn.classList.add('button', 'error-button-back');
22+
backBtn.href = pathname;
23+
backBtn.textContent = 'Go back';
24+
backBtn.title = 'Go back';
25+
const btnContainer = document.querySelector('.button-container');
26+
btnContainer.append(backBtn);
27+
}
28+
}
29+
sampleRUM('404', { source: document.referrer, target: window.location.href });
30+
});
31+
</script>
32+
<link rel="stylesheet" href="/styles/styles.css">
33+
<style>
34+
main.error {
35+
min-height: calc(100vh - var(--nav-height));
36+
display: flex;
37+
align-items: center;
38+
}
39+
40+
main.error .error-number {
41+
width: 100%;
42+
}
43+
44+
main.error .error-number text {
45+
font-family: var(--fixed-font-family);
46+
}
47+
</style>
48+
<link rel="stylesheet" href="/styles/lazy-styles.css">
49+
</head>
50+
51+
<body>
52+
<header></header>
53+
<main class="error">
54+
<div class="section">
55+
<svg viewBox="1 0 38 18" class="error-number">
56+
<text x="0" y="17">404</text>
57+
</svg>
58+
<h2 class="error-message">Page Not Found</h2>
59+
<p class="button-container">
60+
<a href="/" class="button secondary error-button-home">Go home</a>
61+
</p>
62+
</div>
63+
</main>
64+
<footer></footer>
65+
</body>
66+
67+
</html>

CHANGELOG.md

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# [1.3.0](https://github.com/adobe/aem-boilerplate/compare/v1.2.2...v1.3.0) (2023-11-30)
2+
3+
4+
### Bug Fixes
5+
6+
* attempt to fix release ([5bb8f73](https://github.com/adobe/aem-boilerplate/commit/5bb8f7302c70e98a60fd9b8a38f63577f90d7414))
7+
* **build:** fix org in issues URL ([7226d84](https://github.com/adobe/aem-boilerplate/commit/7226d8465e0f5d3c2f4c49bacfbc758c6da5f823))
8+
* **build:** no double slashes in issues url ([1191064](https://github.com/adobe/aem-boilerplate/commit/119106489e1bfb92c80aa55cc2b634496915cfc1))
9+
* **github:** increase default permissions for cleanup action ([f8ed051](https://github.com/adobe/aem-boilerplate/commit/f8ed05169e841a21f1a17c664ace76942d7700c8))
10+
* **github:** restrict running of action to initial commit on main branch ([1a990c2](https://github.com/adobe/aem-boilerplate/commit/1a990c25a4132a50e8c73f80c57845d7d9657399))
11+
* icons no more svgs ([#267](https://github.com/adobe/aem-boilerplate/issues/267)) ([2d4cfa7](https://github.com/adobe/aem-boilerplate/commit/2d4cfa73a9c35c065e9dd2096a9bab3637ddd9b4))
12+
* **lib:** update scripts/aem.js to [email protected] ([#266](https://github.com/adobe/aem-boilerplate/issues/266)) ([2d61c6a](https://github.com/adobe/aem-boilerplate/commit/2d61c6a9fb0905159a568abfe73f4d09dfc0846a))
13+
* rescope icon identifiers to avoid clashing references across icons ([#241](https://github.com/adobe/aem-boilerplate/issues/241)) ([e8dc533](https://github.com/adobe/aem-boilerplate/commit/e8dc53350de838a7dfa094bbbf62c80bdaffdca2)), closes [#235](https://github.com/adobe/aem-boilerplate/issues/235)
14+
* sampleRUM always for checkpoint to be called even if RUM not selected ([fcca39d](https://github.com/adobe/aem-boilerplate/commit/fcca39dd4f5fd2aef6852580873ab4b2cce1e2af))
15+
* trigger release ([afbd201](https://github.com/adobe/aem-boilerplate/commit/afbd201189b13a238ad4709923a5ad9b94dc73eb))
16+
17+
18+
### Features
19+
20+
* add capability to patch block config at runtime ([#246](https://github.com/adobe/aem-boilerplate/issues/246)) ([a774acc](https://github.com/adobe/aem-boilerplate/commit/a774acc651359137422ea734d014164509ae5940))
21+
* enable listeners to all RUM events, not just the sampled ones ([871ede4](https://github.com/adobe/aem-boilerplate/commit/871ede401d2d57c8825f8970f3b28cd9de5f27f8))
22+
* use aem.js ([#255](https://github.com/adobe/aem-boilerplate/issues/255)) ([f5ab4df](https://github.com/adobe/aem-boilerplate/commit/f5ab4df26a992f70a123f56b08062f7dc0b47dae))
23+
24+
## [1.2.2](https://github.com/elc9aya2ls612j/aem-boilerplate/compare/v1.2.1...v1.2.2) (2023-06-29)
25+
26+
27+
### Bug Fixes
28+
29+
* **github:** use double quotes ([d7e285d](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/d7e285dbb452617a5166569f91da4cb376548a38))
30+
31+
## [1.2.1](https://github.com/elc9aya2ls612j/aem-boilerplate/compare/v1.2.0...v1.2.1) (2023-06-29)
32+
33+
34+
### Bug Fixes
35+
36+
* **github:** create and ignore bak files ([ac087b6](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/ac087b61d3e44910d980b0d9e7aead0f2ed83873))
37+
38+
# [1.2.0](https://github.com/elc9aya2ls612j/aem-boilerplate/compare/v1.1.0...v1.2.0) (2023-06-29)
39+
40+
41+
### Features
42+
43+
* **github:** populate pull request template ([4ccb759](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/4ccb7592a84fdc0d3d234fc4da5bdf94a026ff1d))
44+
45+
# [1.1.0](https://github.com/elc9aya2ls612j/aem-boilerplate/compare/v1.0.5...v1.1.0) (2023-06-29)
46+
47+
48+
### Features
49+
50+
* **github:** remove dependencies upon fork, fill in readme ([7e60519](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/7e60519c8ea97640bcb064cb3592990989fe10ef))
51+
52+
## [1.0.5](https://github.com/elc9aya2ls612j/aem-boilerplate/compare/v1.0.4...v1.0.5) (2023-06-29)
53+
54+
55+
### Bug Fixes
56+
57+
* trigger release ([2c3244f](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/2c3244fc181fd900293bbd7e67ab8e68e5d83d5d))
58+
* trigger release ([5ac78b0](https://github.com/elc9aya2ls612j/aem-boilerplate/commit/5ac78b07955c0b75a37dfb293a5d616b7bdaffba))

CODE_OF_CONDUCT.md

+74
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
# Adobe Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as
6+
contributors and maintainers pledge to making participation in our project and
7+
our community a harassment-free experience for everyone, regardless of age, body
8+
size, disability, ethnicity, gender identity and expression, level of experience,
9+
nationality, personal appearance, race, religion, or sexual identity and
10+
orientation.
11+
12+
## Our Standards
13+
14+
Examples of behavior that contributes to creating a positive environment
15+
include:
16+
17+
* Using welcoming and inclusive language
18+
* Being respectful of differing viewpoints and experiences
19+
* Gracefully accepting constructive criticism
20+
* Focusing on what is best for the community
21+
* Showing empathy towards other community members
22+
23+
Examples of unacceptable behavior by participants include:
24+
25+
* The use of sexualized language or imagery and unwelcome sexual attention or
26+
advances
27+
* Trolling, insulting/derogatory comments, and personal or political attacks
28+
* Public or private harassment
29+
* Publishing others' private information, such as a physical or electronic
30+
address, without explicit permission
31+
* Other conduct which could reasonably be considered inappropriate in a
32+
professional setting
33+
34+
## Our Responsibilities
35+
36+
Project maintainers are responsible for clarifying the standards of acceptable
37+
behavior and are expected to take appropriate and fair corrective action in
38+
response to any instances of unacceptable behavior.
39+
40+
Project maintainers have the right and responsibility to remove, edit, or
41+
reject comments, commits, code, wiki edits, issues, and other contributions
42+
that are not aligned to this Code of Conduct, or to ban temporarily or
43+
permanently any contributor for other behaviors that they deem inappropriate,
44+
threatening, offensive, or harmful.
45+
46+
## Scope
47+
48+
This Code of Conduct applies both within project spaces and in public spaces
49+
when an individual is representing the project or its community. Examples of
50+
representing a project or community include using an official project e-mail
51+
address, posting via an official social media account, or acting as an appointed
52+
representative at an online or offline event. Representation of a project may be
53+
further defined and clarified by project maintainers.
54+
55+
## Enforcement
56+
57+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
58+
reported by contacting the project team at [email protected]. All
59+
complaints will be reviewed and investigated and will result in a response that
60+
is deemed necessary and appropriate to the circumstances. The project team is
61+
obligated to maintain confidentiality with regard to the reporter of an incident.
62+
Further details of specific enforcement policies may be posted separately.
63+
64+
Project maintainers who do not follow or enforce the Code of Conduct in good
65+
faith may face temporary or permanent repercussions as determined by other
66+
members of the project's leadership.
67+
68+
## Attribution
69+
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71+
available at [http://contributor-covenant.org/version/1/4][version]
72+
73+
[homepage]: http://contributor-covenant.org
74+
[version]: http://contributor-covenant.org/version/1/4/

0 commit comments

Comments
 (0)