Skip to content

Commit

Permalink
prettier: format files
Browse files Browse the repository at this point in the history
  • Loading branch information
victorcg88 committed Nov 26, 2024
1 parent ab9bdad commit 7e7d894
Show file tree
Hide file tree
Showing 104 changed files with 1,977 additions and 1,994 deletions.
22 changes: 11 additions & 11 deletions .github/CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,23 @@ diverse, inclusive, and healthy community.
Examples of behavior that contributes to a positive environment for our
community include:

* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
- Demonstrating empathy and kindness toward other people
- Being respectful of differing opinions, viewpoints, and experiences
- Giving and gracefully accepting constructive feedback
- Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the
- Focusing on what is best not just for us as individuals, but for the
overall community

Examples of unacceptable behavior include:

* The use of sexualized language or imagery, and sexual attention or
- The use of sexualized language or imagery, and sexual attention or
advances of any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email
- Trolling, insulting or derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or email
address, without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Enforcement Responsibilities
Expand Down Expand Up @@ -106,7 +106,7 @@ Violating these terms may lead to a permanent ban.
### 4. Permanent Ban

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.

**Consequence**: A permanent ban from any sort of public interaction within
Expand Down
6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
name: Bug report
description: Create a report to help us improve
title: "[BUG]: "
title: '[BUG]: '
labels: [bug]
body:
- type: markdown
attributes:
value: "Thank you for taking the time to provide feedback!"
value: 'Thank you for taking the time to provide feedback!'
- type: markdown
attributes:
value: Before creating a new bug, please check for [existing issues](https://github.com/empathyco/x-archetype/issues).
value: Before creating a new bug, please check for [existing issues](https://github.com/empathyco/x-archetype/issues).
- type: textarea
id: bug-environment
attributes:
Expand Down
24 changes: 12 additions & 12 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
---
name: Feature request
description: Add a new suggestion for feature
title: "[FEATURE]: "
labels: [feature,enhancement]
title: '[FEATURE]: '
labels: [feature, enhancement]
body:
- type: markdown
attributes:
value: "Welcome!"
value: 'Welcome!'
- type: markdown
attributes:
value: When suggesting a new feature for the Interface X project, submit your idea as a user story and provide as much information as possible on how you would solve it, so the team can assess and analyze your idea.
When defining your new feature, you need to consider it from two points of view.

- the **Final User** who accesses the commerce website that uses the component.
value:
When suggesting a new feature for the Interface X project, submit your idea as a user story and provide as much information as possible on how you would solve it, so the team can assess and analyze your idea.
When defining your new feature, you need to consider it from two points of view.

- the **Developer User** who is going to use the component to build a website.

Depending on the feature, you may need to consider one or both.
- the **Final User** who accesses the commerce website that uses the component.

- the **Developer User** who is going to use the component to build a website.

Depending on the feature, you may need to consider one or both.
- type: textarea
id: suggestion
attributes:
label: How can the project be improved?
description: Describe the problem encountered, what you need to solve it, and what you expect. Include details of other requirements that the feature must cover such as dependencies and actions covered by other services.
placeholder:
e.g. Display a list of search queries already performed by the user. / Each search query of the list has a button to delete it from the list. / The list of search queries must be maintained in the same device over time, even when the tab is closed. / If there are no search queries, then nothing should be displayed.
placeholder: e.g. Display a list of search queries already performed by the user. / Each search query of the list has a button to delete it from the list. / The list of search queries must be maintained in the same device over time, even when the tab is closed. / If there are no search queries, then nothing should be displayed.
- type: textarea
id: solution
attributes:
Expand Down
11 changes: 9 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
<!--Please provide a general summary of changes in the PR title -->

# Pull request template
<!--To help reviewers to understand the change you've made, you need to include **key information** in your PR.-->

<!--To help reviewers to understand the change you've made, you need to include **key information** in your PR.-->

Describe the purpose of the change, the specific changes done in detail, and the issue you have fixed.

## Motivation and context

<!--Include information on the purpose of the change and any background information that may help. Why is this change required? What problem does it solve? -->

<!-- List any dependencies that are required for this change. If the change fixes an **open** issue, please link to the issue here.-->
Expand All @@ -13,22 +16,26 @@ Describe the purpose of the change, the specific changes done in detail, and the
- [ ] Open issue. If applicable, link:

## Type of change

<!-- Indicate the type of change involved in the PR -->

- [ ] Bug fix (non-breaking change that fixes an issue)
- [ ] New feature (non-breaking change that adds functionality)
- [ ] Breaking change (fix or feature that causes existing functionality to not work as expected)
- [ ] Change requires a documentation update

## What is the destination branch of this PR?

<!-- Although this may seem obvious, please include the destination branch as an extra check to ensure your PR targets the right branch.-->

- [ ] `Main`
- [ ] Other. Specify:

## How has this been tested?

<!-- Please describe in detail how you tested your changes. Include details of your testing environment, the test cases used, and the tests you ran to see how your change affects other areas of the code, etc.-->

Tests performed according to [testing guidelines](https://github.com/empathyco/x/blob/main/.github/contributing/tests.md):
Tests performed according to [testing guidelines](https://github.com/empathyco/x/blob/main/.github/contributing/tests.md):

## Checklist:

Expand Down
10 changes: 5 additions & 5 deletions .github/actions/deploy/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ inputs:
description: cache value for s3 sync command
required: true
cloudfront_distribution_id:
description: the CloudFront cache id to invalidate
required: true
description: the CloudFront cache id to invalidate
required: true
cloudfront_invalidation_paths:
description: the CloudFront path to invalidate
required: true
description: the CloudFront path to invalidate
required: true
runs:
using: 'composite'
steps:
Expand All @@ -33,4 +33,4 @@ runs:
shell: bash
- name: Invalidate CloudFront cache
run: AWS_MAX_ATTEMPTS=10 aws cloudfront create-invalidation --distribution-id ${{ inputs.cloudfront_distribution_id }} --paths ${{ inputs.cloudfront_invalidation_paths }}
shell: bash
shell: bash
20 changes: 9 additions & 11 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@


# Learn more about CodeQL at https://codeql.github.com/docs/
# Learn more about code scanning at https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning
#
name: "CodeQL"
name: 'CodeQL'

on:
push:
branches: [ "main" ]
branches: ['main']
pull_request:
# The branches below must be a subset of the branches above
branches: [ "main" ]
branches: ['main']
schedule:
# Runs periodically at 00:00 UTC on Monday
- cron: '00 00 * * 1'
Expand All @@ -26,11 +24,11 @@ jobs:
fail-fast: false

steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Checkout repository
uses: actions/checkout@v4

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v3

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
6 changes: 3 additions & 3 deletions .github/workflows/deploy-docker.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
name: Create and publish a Docker image

# Configures this workflow to run every time a change is pushed to the `main` branch.
on:
push:
on:
push:
branches: ['main']

# Defines two custom environment variables for the workflow. These are used for the Container registry domain, and a name for the Docker image that this workflow builds.
Expand All @@ -18,7 +18,7 @@ jobs:
permissions:
contents: read
packages: write
#
#
steps:
- name: Checkout repository
uses: actions/checkout@v4
Expand Down
6 changes: 3 additions & 3 deletions .postcssrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ module.exports = {
require('postcss-import'),
require('postcss-logical'),
require('postcss-dir-pseudo-class'),
require('cssnano')({ preset: ['default', { mergeLonghand: false }] })
]
};
require('cssnano')({ preset: ['default', { mergeLonghand: false }] }),
],
}
88 changes: 44 additions & 44 deletions build/instrumentation.build.mjs
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
import commonjs from '@rollup/plugin-commonjs';
import json from '@rollup/plugin-json';
import resolve from '@rollup/plugin-node-resolve';
import replace from '@rollup/plugin-replace';
import * as fs from 'fs';
import path from 'path';
import copy from 'rollup-plugin-copy';
import del from 'rollup-plugin-delete';
import htmlTemplate from 'rollup-plugin-generate-html-template';
import sourcemaps from 'rollup-plugin-sourcemaps';
import styles from 'rollup-plugin-styles';
import { terser } from 'rollup-plugin-terser';
import typescript from 'rollup-plugin-typescript2';
import { visualizer } from 'rollup-plugin-visualizer';
import vue3 from '@vitejs/plugin-vue';
import commonjs from '@rollup/plugin-commonjs'
import json from '@rollup/plugin-json'
import resolve from '@rollup/plugin-node-resolve'
import replace from '@rollup/plugin-replace'
import * as fs from 'fs'
import path from 'path'
import copy from 'rollup-plugin-copy'
import del from 'rollup-plugin-delete'
import htmlTemplate from 'rollup-plugin-generate-html-template'
import sourcemaps from 'rollup-plugin-sourcemaps'
import styles from 'rollup-plugin-styles'
import { terser } from 'rollup-plugin-terser'
import typescript from 'rollup-plugin-typescript2'
import { visualizer } from 'rollup-plugin-visualizer'
import vue3 from '@vitejs/plugin-vue'

/**
* Creates a rollup configuration for projects that use X-Components. This configuration can be
Expand All @@ -33,7 +33,7 @@ export function createConfig({
output,
plugins = {},
prePlugins = [],
postPlugins = []
postPlugins = [],
} = {}) {
/**
* Merges a default config with the user one coming from this rollup plugin options.
Expand All @@ -45,8 +45,8 @@ export function createConfig({
function mergeConfig(pluginName, defaultConfig = {}) {
return {
...defaultConfig,
...plugins[pluginName]
};
...plugins[pluginName],
}
}

const mergedOutput = {
Expand All @@ -55,8 +55,8 @@ export function createConfig({
sourcemap: true,
assetFileNames: '[name][extname]',
entryFileNames: 'app.js',
...output
};
...output,
}

return {
input,
Expand All @@ -66,46 +66,46 @@ export function createConfig({
...prePlugins,
del(
mergeConfig('del', {
targets: [`${mergedOutput.dir}/*`]
})
targets: [`${mergedOutput.dir}/*`],
}),
),
copy({
targets: [{ src: ['public/**'], dest: `${mergedOutput.dir}` }]
targets: [{ src: ['public/**'], dest: `${mergedOutput.dir}` }],
}),
// Resolving plugins
replace(
mergeConfig('replace', {
'process.env.NODE_ENV': JSON.stringify('production'),
'process.env.VUE_APP_DEVELOPMENT_DOCKER': JSON.stringify(
!!process.env.VUE_APP_DEVELOPMENT_DOCKER
!!process.env.VUE_APP_DEVELOPMENT_DOCKER,
),
STRIP_SSR_INJECTOR: true,
preventAssignment: true
})
preventAssignment: true,
}),
),
commonjs(mergeConfig('commonjs')),
resolve(
mergeConfig('resolve', {
browser: true
})
browser: true,
}),
),
// Code transpiling plugins
vue3(
mergeConfig('vue3', {
template: {
compilerOptions: {
whitespace: 'condense'
}
}
})
whitespace: 'condense',
},
},
}),
),
styles(mergeConfig('styles')),
typescript(
mergeConfig('typescript', {
tsconfigOverride: {
exclude: ['node_modules', '**/*.spec.ts', '*test*']
}
})
exclude: ['node_modules', '**/*.spec.ts', '*test*'],
},
}),
),
json(),
htmlTemplate(
Expand All @@ -116,22 +116,22 @@ export function createConfig({
'<script type="module" src="./src/main.ts"></script>': '',
'<load src="node_modules/@empathyco/x-archetype-utils/dist/home/home-template.html" />':
fs.readFileSync(
'node_modules/@empathyco/x-archetype-utils/dist/home/home-template.html'
)
'node_modules/@empathyco/x-archetype-utils/dist/home/home-template.html',
),
},
attrs: ["type='module'"]
})
attrs: ["type='module'"],
}),
),
sourcemaps(mergeConfig('sourcemaps')),
terser(
mergeConfig('terser', {
output: { comments: false }
})
output: { comments: false },
}),
),
/* Can't calculate real minified size with `sourcemap: true` and `gzipSize: true`:
https://github.com/btd/rollup-plugin-visualizer/issues/72 */
visualizer(mergeConfig('visualizer', { sourcemap: true })),
...postPlugins
]
};
...postPlugins,
],
}
}
Loading

0 comments on commit 7e7d894

Please sign in to comment.