Skip to content

Commit

Permalink
Merge pull request #1 from shaal/patch-1
Browse files Browse the repository at this point in the history
Patch 1
  • Loading branch information
aellison authored Jul 3, 2024
2 parents 0039cd8 + bb88c50 commit 29dd442
Show file tree
Hide file tree
Showing 77 changed files with 16,343 additions and 1 deletion.
19 changes: 19 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
node_modules/*
docs/*
dist/*
docs-src/*
rollup.config.js
custom-elements.json
component-list.json
resolved-outline-config.ts
resolved-tailwind-config.ts
.history/
storybook-static/
*.js
*.lit.ts
.github/
.octane-ci/
.bin/
.docksal/
.yarn/
project/
55 changes: 55 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
{
"root": true,
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 2020,
"sourceType": "module"
},
"plugins": ["@typescript-eslint"],
"env": {
"browser": true
},
"globals": {
"process": "readonly"
},
"rules": {
"no-prototype-builtins": "off",
"no-nested-ternary": 2,
"@typescript-eslint/ban-types": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/explicit-module-boundary-types": "off",
"@typescript-eslint/no-explicit-any": "error",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-unused-vars": [
"warn",
{
"argsIgnorePattern": "^_"
}
]
},
"overrides": [
{
"files": ["rollup.config.js", "web-test-runner.config.js"],
"env": {
"node": true
}
},
{
"files": [
"*_test.ts",
"**/custom_typings/*.ts",
"packages/lit-ssr/src/test/integration/tests/**",
"packages/lit-ssr/src/lib/util/parse5-utils.ts"
],
"rules": {
"@typescript-eslint/no-explicit-any": "off"
}
}
]
}
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
node_modules/
dist/
storybook-static/
.yarn/install-state.gz
.yarn/unplugged/
12 changes: 12 additions & 0 deletions .gitpod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
tasks:
- command: |
yarn
time yarn build
yarn start
ports:
- port: 6001
visibility: public
onOpen: open-browser
- port: 6002
visibility: public
29 changes: 29 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
dist/
www/
dev/
loader/
storybook-static/
rollup.config.js
custom-elements.json
component-list.json
resolved-outline-config.ts
resolved-tailwind-config.ts
src/components.d.ts
*.md
.history/
package-lock.json
docs/
.gitlab-ci.yml
.gitlab-ci/*
*.lit.ts
*.stories.mdx
*.stories.ts
*.stories.js
.github/
.octane-ci/
.bin/
.docksal/
.yarn/
project/
outline.theme.css
**/vars-*.css
12 changes: 12 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"arrowParens": "avoid",
"bracketSpacing": true,
"jsxSingleQuote": false,
"quoteProps": "consistent",
"printWidth": 80,
"semi": true,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "es5",
"useTabs": false
}
22 changes: 22 additions & 0 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import type { StorybookConfig } from '@storybook/web-components-vite';
import { mergeConfig } from 'vite';

const config: StorybookConfig = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: ['@storybook/addon-links', '@storybook/addon-essentials'],
framework: {
name: '@storybook/web-components-vite',
options: {},
},
staticDirs: ['../public', '../dist'],
async viteFinal(config, { configType }) {
// Be sure to return the customized config
return mergeConfig(config, {
// Customize the Vite config for Storybook
resolve: {
alias: { foo: 'bar' },
},
});
},
};
export default config;
2 changes: 2 additions & 0 deletions .storybook/preview-head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<script src="/dist/index.js" type="module"></script>
<link rel="stylesheet" href="/dist/global.css" />
24 changes: 24 additions & 0 deletions .storybook/preview.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import type { Preview } from '@storybook/web-components';

const preview: Preview = {
parameters: {
options: {
storySort: {
order: [
'Getting Started',
'Documentation',
'Design Tokens',
'Media',
'Navigation',
'Content',
'Templates',
'Pages',
'Code Examples',
'Utility Components',
],
},
},
},
};

export default preview;
893 changes: 893 additions & 0 deletions .yarn/releases/yarn-4.1.0.cjs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
nodeLinker: node-modules
yarnPath: .yarn/releases/yarn-4.1.0.cjs
45 changes: 44 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,44 @@
# chn1-search
# CHN-Yext

## Preview in Gitpod
https://gitpod.io/#https://github.com/phase2/chn-yext

## Overview
This package contains the necessary files and configurations to set up and run the CHN-Yext project.

## Installation and Setup

Follow these steps to get the project up and running on your local machine:

### Prerequisites

- Ensure you have [Node.js](https://nodejs.org/) installed on your system.
- Yarn package manager is required. If you do not have Yarn installed, you can install it by running:
```bash
npm install -g yarn
```

### Installation

1. Clone the repository to your local machine.
2. Navigate to the project directory.
3. Install the dependencies:
```bash
yarn install
```

### Building the Project

To build the project, run the following command:
```bash
yarn build
```
This command compiles the source code and generates output files in the `dist` directory.

### Viewing the Application

After building the project, open the `build.html` file in your web browser to view the application.

## Support

For any issues or questions, please open an issue on the GitHub repository issue tracker.
14 changes: 14 additions & 0 deletions build.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>CHN Yext</title>
<script src="/dist/index.js" type="module"></script>
<link rel="stylesheet" href="/dist/style.css" />
</head>

<body>
<outline-yext-universal></outline-yext-universal>
</body>
</html>
31 changes: 31 additions & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/**
* This configuration file for commitlint extends the default configuration
* provided by '@phase2/outline-config/commitlint.config'.
*
* The process of extending the configuration works in two steps:
*
* 1. Creating a Baseline Default:
* The default configuration is a set of rules defined in
* '@phase2/outline-config/commitlint.config'. These rules provide a
* baseline standard for commit messages, ensuring consistency and
* readability across all commits.
*
* 2. Allowing Project-Specific Alterations:
* By extending the default configuration in this file, we allow for
* project-specific alterations. This means that while the baseline rules
* are followed, there is flexibility for the project to define its own
* rules or override the default ones. This is done by adding or modifying
* rules in this file.
*
* If a project decides it doesn't need the default configuration, it can
* completely overwrite it by not extending '@phase2/outline-config/commitlint.config'
* and defining its own rules from scratch.
*
* The use of the spread operator (...) before 'defaultConfig' ensures that
* the rules from the default configuration are correctly imported and
* applied in this file.
*/
const defaultConfig = require(`@phase2/outline-config/commitlint.config`);
module.exports = {
...defaultConfig,
};
37 changes: 37 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Component Test Page</title>
<script src="/src/index.ts" type="module"></script>
<!--
To include the necessary assets for testing, you have several options:
1. Full Production Bundle: This is the entire application bundled together.
You can include it by uncommenting the following line:
<script src="dist/index.js" type="module"></script>
2. Individual Components: If you want to test specific components, you can
import them individually. You'll need to know the path to the component
file in the 'dist' directory. For example:
<script src="dist/components/your-component.js" type="module"></script>
<script src="/src/components/your-component.ts" type="module"></script>
3. Standard Includes: These are common files that are often needed in the
head tag. For example, a global stylesheet is included in this file:
<link rel="stylesheet" href="public/global.css" />
Remember to replace 'your-component' with the name of the component you want
to test. Also, ensure the paths to the files are correct relative to this
HTML file.
-->
<!-- <script src="dist/index.mjs" type="module"></script> -->
<link rel="stylesheet" href="/global.css" />
</head>

<body>
<outline-yext-universal></outline-yext-universal>
</body>
</html>
38 changes: 38 additions & 0 deletions outline.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
const destBasePath = 'dist';

const config = {
destBasePath,
assets: {
dir: ['src/assets'],
sync: ['dist', 'src/.storybook/static/dist'],
},
css: {
global: [
{
src: '/public/global.css',
dest: `${destBasePath}/global.css`,
},
// {
// src: 'src/tailwind.css',
// dest: `${destBasePath}/tailwind.css`,
// },
],
},
js: {
output: {
lazy: false,
eager: false,
full: true,
data: false,
},
},
youtube: {
defaultVideo: 'xiqgG8HUZXE',
},
vimeo: {
defaultVideo: '432639001',
},
excludedStories: [],
};

export default config;
Loading

0 comments on commit 29dd442

Please sign in to comment.