diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index d111206e79..0000000000 --- a/.eslintrc +++ /dev/null @@ -1,218 +0,0 @@ -{ - "parser": "babel-eslint", - "plugins": [ - "react" - ], - "env": { - "browser": true, - "node": true, - "jasmine" : true - }, - "globals" : { - "adz": true, - jQuery: true - }, - "ecmaFeatures": { - "arrowFunctions": true, - "blockBindings": true, - "classes": true, - "defaultParams": true, - "destructuring": true, - "forOf": true, - "generators": false, - "modules": true, - "objectLiteralComputedProperties": true, - "objectLiteralDuplicateProperties": false, - "objectLiteralShorthandMethods": true, - "objectLiteralShorthandProperties": true, - "spread": true, - "superInFunctions": true, - "templateStrings": true, - "jsx": true - }, - "rules": { -/** - * Strict mode - */ - // babel inserts "use strict"; for us - // http://eslint.org/docs/rules/strict - "strict": [2, "never"], - -/** - * ES6 - */ - "no-var": 2, // http://eslint.org/docs/rules/no-var - -/** - * Variables - */ - "no-shadow": 2, // http://eslint.org/docs/rules/no-shadow - "no-shadow-restricted-names": 2, // http://eslint.org/docs/rules/no-shadow-restricted-names - "no-unused-vars": [2, { // http://eslint.org/docs/rules/no-unused-vars - "vars": "local", - "args": "after-used" - }], - "no-use-before-define": 2, // http://eslint.org/docs/rules/no-use-before-define - -/** - * Possible errors - */ - "comma-dangle": [2, "never"], // http://eslint.org/docs/rules/comma-dangle - "no-cond-assign": [2, "always"], // http://eslint.org/docs/rules/no-cond-assign - "no-console": 1, // http://eslint.org/docs/rules/no-console - "no-debugger": 1, // http://eslint.org/docs/rules/no-debugger - "no-alert": 1, // http://eslint.org/docs/rules/no-alert - "no-constant-condition": 1, // http://eslint.org/docs/rules/no-constant-condition - "no-dupe-keys": 2, // http://eslint.org/docs/rules/no-dupe-keys - "no-duplicate-case": 2, // http://eslint.org/docs/rules/no-duplicate-case - "no-empty": 2, // http://eslint.org/docs/rules/no-empty - "no-ex-assign": 2, // http://eslint.org/docs/rules/no-ex-assign - "no-extra-boolean-cast": 0, // http://eslint.org/docs/rules/no-extra-boolean-cast - "no-extra-semi": 2, // http://eslint.org/docs/rules/no-extra-semi - "no-func-assign": 2, // http://eslint.org/docs/rules/no-func-assign - "no-inner-declarations": 2, // http://eslint.org/docs/rules/no-inner-declarations - "no-invalid-regexp": 2, // http://eslint.org/docs/rules/no-invalid-regexp - "no-irregular-whitespace": 2, // http://eslint.org/docs/rules/no-irregular-whitespace - "no-obj-calls": 2, // http://eslint.org/docs/rules/no-obj-calls - "no-reserved-keys": 2, // http://eslint.org/docs/rules/no-reserved-keys - "no-sparse-arrays": 2, // http://eslint.org/docs/rules/no-sparse-arrays - "no-unreachable": 2, // http://eslint.org/docs/rules/no-unreachable - "use-isnan": 2, // http://eslint.org/docs/rules/use-isnan - "block-scoped-var": 2, // http://eslint.org/docs/rules/block-scoped-var - -/** - * Best practices - */ - "consistent-return": 2, // http://eslint.org/docs/rules/consistent-return - "curly": [2, "multi-line"], // http://eslint.org/docs/rules/curly - "default-case": 2, // http://eslint.org/docs/rules/default-case - "dot-notation": [2, { // http://eslint.org/docs/rules/dot-notation - "allowKeywords": true - }], - "eqeqeq": 2, // http://eslint.org/docs/rules/eqeqeq - "guard-for-in": 2, // http://eslint.org/docs/rules/guard-for-in - "no-caller": 2, // http://eslint.org/docs/rules/no-caller - "no-else-return": 2, // http://eslint.org/docs/rules/no-else-return - "no-eq-null": 2, // http://eslint.org/docs/rules/no-eq-null - "no-eval": 2, // http://eslint.org/docs/rules/no-eval - "no-extend-native": 2, // http://eslint.org/docs/rules/no-extend-native - "no-extra-bind": 2, // http://eslint.org/docs/rules/no-extra-bind - "no-fallthrough": 2, // http://eslint.org/docs/rules/no-fallthrough - "no-floating-decimal": 2, // http://eslint.org/docs/rules/no-floating-decimal - "no-implied-eval": 2, // http://eslint.org/docs/rules/no-implied-eval - "no-lone-blocks": 2, // http://eslint.org/docs/rules/no-lone-blocks - "no-loop-func": 2, // http://eslint.org/docs/rules/no-loop-func - "no-multi-str": 2, // http://eslint.org/docs/rules/no-multi-str - "no-native-reassign": 2, // http://eslint.org/docs/rules/no-native-reassign - "no-new": 2, // http://eslint.org/docs/rules/no-new - "no-new-func": 2, // http://eslint.org/docs/rules/no-new-func - "no-new-wrappers": 2, // http://eslint.org/docs/rules/no-new-wrappers - "no-octal": 2, // http://eslint.org/docs/rules/no-octal - "no-octal-escape": 2, // http://eslint.org/docs/rules/no-octal-escape - "no-param-reassign": 2, // http://eslint.org/docs/rules/no-param-reassign - "no-proto": 2, // http://eslint.org/docs/rules/no-proto - "no-redeclare": 2, // http://eslint.org/docs/rules/no-redeclare - "no-return-assign": 2, // http://eslint.org/docs/rules/no-return-assign - "no-script-url": 2, // http://eslint.org/docs/rules/no-script-url - "no-self-compare": 2, // http://eslint.org/docs/rules/no-self-compare - "no-sequences": 2, // http://eslint.org/docs/rules/no-sequences - "no-throw-literal": 2, // http://eslint.org/docs/rules/no-throw-literal - "no-with": 2, // http://eslint.org/docs/rules/no-with - "radix": 2, // http://eslint.org/docs/rules/radix - "vars-on-top": 2, // http://eslint.org/docs/rules/vars-on-top - "wrap-iife": [2, "any"], // http://eslint.org/docs/rules/wrap-iife - "yoda": 2, // http://eslint.org/docs/rules/yoda - -/** - * Style - */ - "indent": [2, 2], // http://eslint.org/docs/rules/ - "brace-style": [2, // http://eslint.org/docs/rules/brace-style - "1tbs", { - "allowSingleLine": true - }], - "quotes": [ - 2, "single", "avoid-escape" // http://eslint.org/docs/rules/quotes - ], - "camelcase": [2, { // http://eslint.org/docs/rules/camelcase - "properties": "never" - }], - "comma-spacing": [2, { // http://eslint.org/docs/rules/comma-spacing - "before": false, - "after": true - }], - "comma-style": [2, "last"], // http://eslint.org/docs/rules/comma-style - "eol-last": 2, // http://eslint.org/docs/rules/eol-last - "key-spacing": [2, { // http://eslint.org/docs/rules/key-spacing - "beforeColon": false, - "afterColon": true - }], - "new-cap": [2, { // http://eslint.org/docs/rules/new-cap - "newIsCap": true, - newIsCapExceptions : ['moment'] - }], - "no-multiple-empty-lines": [2, { // http://eslint.org/docs/rules/no-multiple-empty-lines - "max": 2 - }], - "no-nested-ternary": 2, // http://eslint.org/docs/rules/no-nested-ternary - "no-new-object": 2, // http://eslint.org/docs/rules/no-new-object - "no-spaced-func": 2, // http://eslint.org/docs/rules/no-spaced-func - "no-trailing-spaces": 2, // http://eslint.org/docs/rules/no-trailing-spaces - "no-wrap-func": 2, // http://eslint.org/docs/rules/no-wrap-func - "no-underscore-dangle": 0, // http://eslint.org/docs/rules/no-underscore-dangle - "one-var": [2, "never"], // http://eslint.org/docs/rules/one-var - "padded-blocks": [2, "never"], // http://eslint.org/docs/rules/padded-blocks - "semi": [2, "always"], // http://eslint.org/docs/rules/semi - "semi-spacing": [2, { // http://eslint.org/docs/rules/semi-spacing - "before": false, - "after": true - }], - "space-after-keywords": 2, // http://eslint.org/docs/rules/space-after-keywords - "space-before-blocks": 2, // http://eslint.org/docs/rules/space-before-blocks - "space-before-function-paren": [2, "never"], // http://eslint.org/docs/rules/space-before-function-paren - "space-infix-ops": 2, // http://eslint.org/docs/rules/space-infix-ops - "space-return-throw-case": 2, // http://eslint.org/docs/rules/space-return-throw-case - "spaced-line-comment": 2, // http://eslint.org/docs/rules/spaced-line-comment - -/** - * JSX style - */ - "react/display-name": 0, - "react/jsx-boolean-value": 2, - "react/jsx-quotes": [2, "double"], - "react/jsx-no-undef": 2, - "react/jsx-sort-props": 0, - "react/jsx-sort-prop-types": 0, - "react/jsx-uses-react": 2, - "react/jsx-uses-vars": 2, - "react/no-did-mount-set-state": [2, "allow-in-func"], - "react/no-did-update-set-state": 2, - "react/no-unknown-property": 2, - "react/prop-types": 2, - "react/react-in-jsx-scope": 2, - "react/self-closing-comp": 2, - "react/wrap-multilines": 2, - "react/sort-comp": [2, { - "order": [ - "displayName", - "mixins", - "statics", - "propTypes", - "getDefaultProps", - "getInitialState", - "componentWillMount", - "componentDidMount", - "componentWillReceiveProps", - "shouldComponentUpdate", - "componentWillUpdate", - "componentWillUnmount", - "componentDidUpdate", - "/^on.+$/", - "/^handle.+$/", - "/^get.+$/", - "/^render.+$/", - "render" - ] - }] - } -} diff --git a/.flowconfig b/.flowconfig deleted file mode 100644 index 5d5bb7a74e..0000000000 --- a/.flowconfig +++ /dev/null @@ -1,4 +0,0 @@ -[include] -./node_modules/immutable -./node_modules/react -./src diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..6313b56c57 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto eol=lf diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000000..8cd9252d9b --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @amanmahajan7 @nstepien diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000000..cda0d86965 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,27 @@ +--- +name: Bug report +about: Create a bug report +title: '' +labels: 'Status: Unconfirmed' +assignees: '' +--- + +## Describe the bug + +## To Reproduce + +1. +2. + +## Expected behavior + +## Link to Minimal Reproducible Example + + + +## Environment + +- `react-data-grid` version: +- `react`/`react-dom` version: + +## Additional context diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000000..f0eb8fdee2 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,4 @@ +contact_links: + - name: Questions and discussions + url: https://github.com/Comcast/react-data-grid/discussions + about: Please check the discussions tab for help and discussions. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000000..4a9623b95e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,11 @@ +--- +name: Feature request +about: Request a new feature or enhancement +title: '' +labels: Feature Request +assignees: '' +--- + +## Use case + +## Proposed solution diff --git a/.github/codecov.yml b/.github/codecov.yml new file mode 100644 index 0000000000..2fdd62ca4f --- /dev/null +++ b/.github/codecov.yml @@ -0,0 +1,17 @@ +# https://docs.codecov.com/docs/commit-status +coverage: + status: + project: + default: + informational: true + patch: off + +# https://docs.codecov.com/docs/pull-request-comments +comment: + layout: 'diff, files' + require_changes: true + +# https://docs.codecov.com/docs/node +parsers: + javascript: + enable_partials: yes diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000000..3e6e2480c6 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,25 @@ +# https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/configuration-options-for-dependency-updates + +version: 2 +updates: + - package-ecosystem: 'npm' + directory: '/' + schedule: + interval: 'weekly' + groups: + react: + patterns: + - 'react' + - 'react-dom' + typescript-eslint: + patterns: + - '@typescript-eslint/*' + vitest: + patterns: + - 'vitest' + - '@vitest/*' + + - package-ecosystem: 'github-actions' + directory: '/' + schedule: + interval: 'weekly' diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000000..8a755ee0a9 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,68 @@ +name: CI +on: + push: + branches: + - main + pull_request: + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + + - uses: actions/setup-node@v6 + with: + node-version: 25 + check-latest: true + + - name: Install dependencies + run: npm i + + - name: Biome + run: node --run biome:ci + + - name: Typecheck + run: node --run typecheck + + - name: ESLint + run: node --run eslint + + - name: Prettier + run: node --run prettier:check + + - name: Bundle + run: node --run build + + - name: Build website + run: node --run build:website + + - name: Install Playwright Browsers + run: npx playwright install chromium firefox + + - name: Test + run: node --run test + timeout-minutes: 4 + + - name: Visual regression test + run: node --run visual + + - name: Upload coverage + uses: codecov/codecov-action@v5 + with: + token: ${{ secrets.CODECOV_TOKEN }} + + - name: Deploy gh-pages + if: github.event_name == 'push' && github.ref == 'refs/heads/main' + run: | + git config --global user.email 'action@github.com' + git config --global user.name 'GitHub Action' + git fetch origin gh-pages + git worktree add gh-pages gh-pages + cd gh-pages + git rm -r . + mv ../dist/* . + touch .nojekyll + git add . + git commit -m "gh-pages deployment" || echo "Nothing to commit" + git push -f https://comcast:${{secrets.GITHUB_TOKEN}}@github.com/Comcast/react-data-grid.git diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000000..4c075a3d94 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,77 @@ +name: Publish + +on: + workflow_dispatch: + inputs: + version: + description: 'Version to publish (e.g., 0.1.1, 0.2.0, 1.0.0)' + required: true + type: string + +jobs: + publish: + name: Publish + runs-on: ubuntu-latest + permissions: + contents: write + id-token: write + + steps: + - uses: actions/checkout@v6 + with: + fetch-depth: 0 + + - uses: actions/setup-node@v6 + with: + node-version: 25 + check-latest: true + registry-url: 'https://registry.npmjs.org/' + + - name: Install dependencies + run: npm i + + - name: Biome + run: node --run biome:ci + + - name: Typecheck + run: node --run typecheck + + - name: ESLint + run: node --run eslint + + - name: Prettier + run: node --run prettier:check + + - name: Bundle + run: node --run build + + - name: Build website + run: node --run build:website + + - name: Install Playwright Browsers + run: npx playwright install chromium firefox + + - name: Test + run: node --run test + timeout-minutes: 4 + + - name: Visual regression test + run: node --run visual + + - name: Update version + run: | + git config user.name "${{ github.actor }}" + git config user.email "${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com" + npm version ${{ inputs.version }} + + # https://docs.npmjs.com/trusted-publishers + - name: Publish to npm + run: npm publish --tag latest + + - name: Push tag + run: git push origin v${{ inputs.version }} + + - name: Create GitHub Release + run: gh release create v${{ inputs.version }} --title "v${{ inputs.version }}" --generate-notes + env: + GH_TOKEN: ${{ github.token }} diff --git a/.github/workflows/update-screenshots.yml b/.github/workflows/update-screenshots.yml new file mode 100644 index 0000000000..f7f0e9d6d9 --- /dev/null +++ b/.github/workflows/update-screenshots.yml @@ -0,0 +1,57 @@ +name: Update Screenshots + +on: + pull_request: + types: [labeled] + workflow_dispatch: + +env: + AUTHOR_NAME: 'github-actions[bot]' + AUTHOR_EMAIL: '41898282+github-actions[bot]@users.noreply.github.com' + COMMIT_MESSAGE: | + Update screenshots + + Co-authored-by: ${{ github.actor }} + +jobs: + update-screenshots: + if: ${{ github.event.label.name == 'Update Screenshots' || github.event_name == 'workflow_dispatch' }} + runs-on: ubuntu-latest + + permissions: + contents: write + pull-requests: write + + # one at a time per branch + concurrency: + group: update-screenshots@${{ github.head_ref }} + cancel-in-progress: true + + steps: + - uses: actions/checkout@v6 + with: + ref: ${{ github.head_ref }} + - uses: actions/setup-node@v6 + with: + node-version: 25 + check-latest: true + - name: Remove label + if: github.event_name == 'pull_request' + run: gh pr edit --remove-label 'Update Screenshots' + env: + GH_TOKEN: ${{ github.token }} + - name: Install dependencies + run: npm i + - name: Install Playwright Browsers + run: npx playwright install chromium firefox + - name: Update screenshots + run: | + rm -r test/visual/__screenshots__ + node --run visual:update + - name: Push new screenshots + run: | + git config --global user.name "${{ env.AUTHOR_NAME }}" + git config --global user.email "${{ env.AUTHOR_EMAIL }}" + git add test/visual/__screenshots__/. + git diff-index --quiet HEAD || git commit -m "${{ env.COMMIT_MESSAGE }}" + git push diff --git a/.gitignore b/.gitignore index a2ba120207..47ab83bf80 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,14 @@ -node_modules -bower_components -lib -**/build -test/reports -test/coverage -dist +/.cache +/coverage +/dist +/lib +/node_modules +/package-lock.json +test/browser/**/__screenshots__ + +npm-debug.log +**.orig +.idea +.vitest-attachments + +__traces__ diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 7a519584d8..0000000000 --- a/.npmignore +++ /dev/null @@ -1,20 +0,0 @@ -src -**/build -webpack.config.js -LICENSE -.eslintrc -test -gulp -examples -coveralls.yml -gulpfile.js -config -.npmrc -.npmrc.enc -appveyor.yml -bower.json -CONTRIBUTING.md -.flowconfig -secure-file -flow -ci diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000000..80bcbed90c --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +legacy-peer-deps = true diff --git a/.npmrc.enc b/.npmrc.enc deleted file mode 100644 index 5582f5f9bd..0000000000 --- a/.npmrc.enc +++ /dev/null @@ -1 +0,0 @@ -h�4(�1Y,��Zpr���q!b�F�L��P��_�u��v��{o{������o'/����HZ@lZ���T~z��� \ No newline at end of file diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000000..2dfabd2544 --- /dev/null +++ b/.prettierignore @@ -0,0 +1 @@ +/website/routeTree.gen.ts diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000000..3ff9ca6132 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,25 @@ +{ + "singleQuote": true, + "trailingComma": "none", + "printWidth": 100, + "plugins": ["@ianvs/prettier-plugin-sort-imports"], + "importOrder": [ + "", + "^react$", + "^react-dom", + "^react", + "", + "^ecij$", + "^clsx$", + "", + "./src", + "./renderers", + "./components", + "./hooks", + "./utils", + "./types", + "^\\.$", + "^\\./", + "^\\.\\./" + ] +} diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000000..f05755bcdb --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,3 @@ +{ + "recommendations": ["dbaeumer.vscode-eslint", "esbenp.prettier-vscode", "biomejs.biome"] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000000..c60cc479e1 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,19 @@ +{ + "editor.codeActionsOnSave": { + "source.fixAll": "explicit" + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "typescript.enablePromptUseWorkspaceTsdk": true, + "typescript.tsdk": "node_modules/typescript/lib", + "files.readonlyInclude": { + "**/routeTree.gen.ts": true + }, + "files.watcherExclude": { + "**/routeTree.gen.ts": true + }, + "search.exclude": { + "**/package-lock.json": true, + "**/routeTree.gen.ts": true + } +} diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000000..6685f21a6f --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,419 @@ +# Changelog + +## v7.0.0-canary.48 + +- Fixed an edge case where clicking outside the grid wouldn't close and commit an open editor quickly enough, resulting in the previous rows state being used by parent components in `click` handlers. ([PR](https://github.com/Comcast/react-data-grid/pull/2415)) +- Support for filters has been removed, along with: ([PR](https://github.com/Comcast/react-data-grid/pull/2412)) + - The `` props: `headerFiltersHeight`, `filters`, `onFiltersChange`, `enableFilterRow` + - `Column.filterRenderer` + - The exports: `FilterRendererProps`, `Filters` +- Optional `Column` props can now also be `null` in addition to `undefined`. ([PR](https://github.com/Comcast/react-data-grid/pull/2409)) + +## v7.0.0-canary.47 + +- Added a third, optional generic on `` to specify the row key type. ([PR](https://github.com/Comcast/react-data-grid/pull/2311)) +- Added the `useRowSelection` hook for custom cell renderers to access `isRowSelected` and `onRowSelectionChange`. ([PR](https://github.com/Comcast/react-data-grid/pull/2338)) +- `HeaderRendererProps.allRowsSelected` tweaks, affecting the `SelectColumn`: ([PR](https://github.com/Comcast/react-data-grid/pull/2402)) + - It will now be `false` when `rows.length === 0` instead of `true`. + - `selectedRows` must contain all the row keys for `allRowsSelected` to be `true`, instead of naively comparing the `size` and `length`. +- Optional props on `` can now also be `null` in addition to `undefined`. ([PR](https://github.com/Comcast/react-data-grid/pull/2406)) + +## v7.0.0-canary.46 + +- Optimize onRowsChange: only update changed rows ([PR](https://github.com/Comcast/react-data-grid/pull/2390)) + +## v7.0.0-canary.45 + +- Fixed issue where the scrollbars would flicker in edge cases ([PR](https://github.com/Comcast/react-data-grid/pull/2389)) + +## v7.0.0-canary.44 + +- Use aria-selected to style selected cell/rows ([PR](https://github.com/Comcast/react-data-grid/pull/2386)) +- Add support for variable row heights ([PR](https://github.com/Comcast/react-data-grid/pull/2384)) + +## v7.0.0-canary.43 + +- Fix `aria-readonly` ([PR](https://github.com/Comcast/react-data-grid/pull/2380)) + +## v7.0.0-canary.42 + +- Add missing `aria-colspan` ([PR](https://github.com/Comcast/react-data-grid/pull/2374)) +- Add `aria-readonly` to readonly cells ([PR](https://github.com/Comcast/react-data-grid/pull/2379)) + +## v7.0.0-canary.41 + +- Fix summary row colSpan ([PR](https://github.com/Comcast/react-data-grid/pull/2372)) +- HeaderCell: Add missing event parameter to onPointerUp, fix #2305 ([PR](https://github.com/Comcast/react-data-grid/pull/2371)) + +## v7.0.0-canary.40 + +- Add `column.colSpan` prop to merge cells ([PR](https://github.com/Comcast/react-data-grid/pull/2356)) +- Removed prefixed css properties from the generated style file ([PR](https://github.com/Comcast/react-data-grid/pull/2370)) + +## v7.0.0-canary.39 + +- Add `enableVirtualization` prop ([PR](https://github.com/Comcast/react-data-grid/pull/2355)). Grid renders all the rows/columns when it is set to false. + +## v7.0.0-canary.38 + +- Fix summary row position ([PR](https://github.com/Comcast/react-data-grid/pull/2335)) + +## v7.0.0-canary.37 + +- Add `summaryRowHeight` prop ([PR](https://github.com/Comcast/react-data-grid/pull/2325)) +- Rollup type definitions ([PR](https://github.com/Comcast/react-data-grid/pull/2301)) + +## v7.0.0-canary.36 + +- Fixed column headers not showing when grid is horizontally scrolled ([PR](https://github.com/Comcast/react-data-grid/pull/2297)) + +## v7.0.0-canary.35 + +- Migrate to css-in-js with linaria ([PR](https://github.com/Comcast/react-data-grid/pull/2256)). RDG now internally uses [linaria](https://github.com/callstack/linaria) to manage styles. The stylesheets are automatically injected and there is no stylesheet to manually import anymore. +- Expose data grid root element reference ([PR](https://github.com/Comcast/react-data-grid/pull/2258)). +- (Bug fix) Tabbing into the grid should initiate keyboard navigation ([PR](https://github.com/Comcast/react-data-grid/pull/2289)). + +## v7.0.0-canary.34 + +- Only show the vertical scrollbar when necessary ([PR](https://github.com/Comcast/react-data-grid/pull/2231)) +- Fix `editorPortalTarget` default value for server-side rendering ([PR](https://github.com/Comcast/react-data-grid/pull/2245)) +- Use grid layout for rows, split column metrics from compute columns ([PR](https://github.com/Comcast/react-data-grid/pull/2272)). Resizing columns no longer recreates columns so less re-renders +- Augment `onRowsChange` with `indexes` and `column` data ([PR](https://github.com/Comcast/react-data-grid/pull/2278)) + +## v7.0.0-canary.33 + +- (Bug) Commit changes before exiting grid ([PR](https://github.com/Comcast/react-data-grid/pull/2224)) + +## v7.0.0-canary.32 + +- Fix importing rdg with webpack 4 ([PR](https://github.com/Comcast/react-data-grid/pull/2221)) + +## v7.0.0-canary.31 + +- (Breaking) Remove some exports from the grid ([PR](https://github.com/Comcast/react-data-grid/pull/2210)) +- Use a pseudo-element for header resizer ([PR](https://github.com/Comcast/react-data-grid/pull/2217)) +- (new) Formatters now receive a new onRowChange prop ([PR](https://github.com/Comcast/react-data-grid/pull/2220)) +- (new) Change `column.name` type from `string` to `string/ReactElement` ([PR](https://github.com/Comcast/react-data-grid/pull/2220)) +- Publish bundles instead of modules, use babel only for transpilation ([PR](https://github.com/Comcast/react-data-grid/pull/2214)) +- Use the new jsx runtime ([PR](https://github.com/Comcast/react-data-grid/pull/2184)). The minimum supported react version is 16.14 now. + +## v7.0.0-canary.30 + +- Forward sorting props to `headerRenderer` ([PR](https://github.com/Comcast/react-data-grid/pull/2204)) +- Disable cell navigation while editing. This behavior can be controlled using the new `column.editorOptions.onNavigation` option ([PR](https://github.com/Comcast/react-data-grid/pull/2196)) + +## v7.0.0-canary.29 + +- Fix crash when `rows` are `undefined` ([PR](https://github.com/Comcast/react-data-grid/pull/2197)) +- Fix a scrolling bug caused by `scroll-behavior: smooth` ([PR](https://github.com/Comcast/react-data-grid/pull/2200)) + +## v7.0.0-canary.28 + +- (Breaking) Removed `onRowsUpdate`, `enableCellCopyPaste`, and `enableCellDragAndDrop` props. Added 2 new props (`onFill` and `onPaste`) ([PR](https://github.com/Comcast/react-data-grid/pull/2194)) +- (Breaking) Rename `enableFilters` to `enableFilterRow` ([PR](https://github.com/Comcast/react-data-grid/pull/2195)) + +## v7.0.0-canary.27 + +- (Breaking) Removed old editor API ([PR](https://github.com/Comcast/react-data-grid/pull/2149)) +- (Breaking) Removed `onCheckCellIsEditable` prop ([PR](https://github.com/Comcast/react-data-grid/pull/2016)). Use `column.editable` instead. + = (Breaking) Replaced rowKey prop with rowKeyGetter ([PR](https://github.com/Comcast/react-data-grid/pull/2190)) + +## v7.0.0-canary.26 + +- Fixed Copy & Paste events not working properly in non-English keyboards ([PR](https://github.com/Comcast/react-data-grid/pull/2097)) + +## v7.0.0-canary.25 + +- Added support for webpack 5 ([PR](https://github.com/Comcast/react-data-grid/pull/2178)) + +## v7.0.0-canary.24 + +- Fixed a bug where grid was getting scrolled on cell focus + +## v7.0.0-canary.23 + +- Minor style fixes + +## v7.0.0-canary.22 + +- Add Grouping ([PR](https://github.com/Comcast/react-data-grid/pull/2106)). Check the new [example](https://comcast.github.io/react-data-grid/#/grouping). +- (Breaking) Removed `height` and `width` props and added new `className` and `style` props. We are now using `ResizeObserver` to calculate all the grid dimensions ([PR](https://github.com/Comcast/react-data-grid/pull/2130)) +- (Breaking) Removed formatterOptions. Grid now handles formatter focus internally so this prop is no longer required ([PR](https://github.com/Comcast/react-data-grid/pull/2138)) +- Added support for React 17 + +## v7.0.0-canary.21 + +- Editor2 bug fixes ([PR](https://github.com/Comcast/react-data-grid/pull/2126)) +- `formatterOptions.focusable` can be a function now so different rows can have different focus behavior for the same column +- Grid now internally uses `ResizeObserver` API to calculate the available width ([PR](https://github.com/Comcast/react-data-grid/pull/2129)) + +## v7.0.0-canary.20 + +- A new editor api that does not require a ref ([PR](https://github.com/Comcast/react-data-grid/pull/2102)) +- A new `columnDefaultOptions` prop. This replaces `minColumnWidth` and `defaultFormatter` props ([PR](https://github.com/Comcast/react-data-grid/pull/2117)) + +## v7.0.0-canary.19 + +- Allow setting ref on `Cell/Row` renderers ([PR](https://github.com/Comcast/react-data-grid/pull/2111)) + +## v7.0.0-canary.18 + +- Accessibility improvements. Added various aria attributes. ([PR](https://github.com/Comcast/react-data-grid/pull/2084)) +- Removed enableCellAutoFocus prop ([PR](https://github.com/Comcast/react-data-grid/pull/2073)) +- Removed InteractionMasks component. This is an internal change to prepare for grouping and it fixes a few selected cell position bugs +- Improved focus for custom formatters using the new formatterOptions ([PR](https://github.com/Comcast/react-data-grid/pull/2104)) + +## v7.0.0-canary.17 + +- Performance improvements ([PR](https://github.com/Comcast/react-data-grid/pull/2015)) +- A new rowClass prop ([PR](https://github.com/Comcast/react-data-grid/pull/2058)) + +## `alpha` to `canary` + +- **Added:** + - **Props:** + - `className` + - `style` + - `onRowsChange` + - `onFill` + - `onPaste` + - `onSelectedCellChange` + - ⚠️ This replaces the `onCellSelected` and `onCellDeSelected` props + - `enableFilterRow` + - ⚠️ This replaces the `enableHeaderFilters` and `column.filterable` props + - `filters` + - `onFiltersChange` + - `rows` + - ⚠️ This replace the `rowGetter` and `rowsCount` props + - `rowClass` + - `defaultColumnOptions` + - ⚠️ This replaces the `minColumnWidth` and `defaultFormatter` props + - `groupBy` + - `rowGrouper` + - More info in [#2106](https://github.com/Comcast/react-data-grid/pull/2106) + - `column.cellClass(row)` function support: + - `column = { ..., cellClass(row) { return string; } }` + - `column.minWidth` + - `column.maxWidth` + - `column.headerCellClass` + - `column.editor` + - New API + - `column.editorOptions` + - More info in [#2102](https://github.com/Comcast/react-data-grid/pull/2102) + - `column.groupFormatter` + - More info in [#2106](https://github.com/Comcast/react-data-grid/pull/2106) + - `scrollToRow` method + - ⚠️ This replaces the `scrollToRowIndex` prop + - Dark mode support + - Dark mode is automatically applied following user preference + - Light and dark modes can be forced by setting the `rdg-light` or `rdg-dark` class names. +- **Removed:** + - **Support:** + - ⚠️ IE11 + - **Packages:** + - ⚠️ `react-data-grid-addons` + - **Props:** + - ⚠️ `width` + - ⚠️ `height` + - ⚠️ `cellContentRenderer` + - ⚠️ `contextMenu` + - Check the [Context Menu](https://comcast.github.io/react-data-grid/#/context-menu) example + - ⚠️ `enableCellSelect` + - ⚠️ `enableCellAutoFocus` + - ⚠️ `getValidFilterValues` + - ⚠️ `onCellCopyPaste` + - ⚠️ `onSelectedCellRangeChange` + - ⚠️ `onCheckCellIsEditable` + - Use `column.editable` instead. + - ⚠️ `onGridKeyDown` + - ⚠️ `onGridKeyUp` + - ⚠️ `onRowDoubleClick` + - ⚠️ `onRowsUpdate` + - Use `onRowsChange`, `onFill`, and `onPaste` instead. + - ⚠️ `onHeaderDrop` + - ⚠️ `draggableHeaderCell` + - Check [#2007](https://github.com/Comcast/react-data-grid/pull/2007) on how to migrate + - ⚠️ `rowGroupRenderer` + - ⚠️ `onRowExpandToggle` + - Check [#2012](https://github.com/Comcast/react-data-grid/pull/2012) on how to migrate + - ⚠️ `rowsContainer` + - ⚠️ Subrow props: `getSubRowDetails`, `onCellExpand`, `onDeleteSubRow`, and `onAddSubRow` + - Check [#1853](https://github.com/Comcast/react-data-grid/pull/1853) on how to migrate + - ⚠️ `cellMetaData` (from `Row` and `Cell` props) + - ⚠️ `value` (from `column.formatter` props) + - **Ref handlers:** + - ⚠️ `openCellEditor`, use `selectCell` instead. + - ⚠️ React elements are no longer supported, please use components instead. + - For example: + ```diff + const column = { + key: 'example', + name: 'Example', + - formatter: + + formatter: (props) => + }; + ``` + - ⚠️ `column.events` + - ⚠️ `column.getCellActions` + - Check [#1845](https://github.com/Comcast/react-data-grid/pull/1845) on how to migrate + - ⚠️ `column.getRowMetaData` + - ⚠️ `column.minColumnWidth` + - ⚠️ `column.filterable` + - ⚠️ `column.draggable` + - ⚠️ `cellRangeSelection.{onStart,onUpdate,onEnd}` + - ⚠️ `fromRowId`, `toRowId`, and `fromRowData` from `onRowsUpdate` argument + - ⚠️ Stopped exporting `HeaderCell` +- **Renamed:** + - ⚠️ `minHeight` to `height` + - ⚠️ `minWidth` to `width` + - ⚠️ `onGridSort` to `onSort` + - ⚠️ `emptyRowsView` to `emptyRowsRenderer` + - ⚠️ `rowKey` to `rowKeyGetter` + - ⚠️ `rowData` to `row` + - ⚠️ `fromRowData` to `fromRow` + - ⚠️ `idx` to `rowIdx` in `Row` renderer +- **Changed:** + - ⚠️ Started publishing ES2019/ESM modules instead of ES5/CommonJS modules. + - Using [`@babel/preset-env`](https://www.npmjs.com/package/@babel/preset-env) with [`core-js`](https://www.npmjs.com/package/core-js) is recommended to enable compatibility for the browsers your project aims to support. + - ⚠️ Improved support for summary rows: + - `summaryRows` types are now independent from `rows` + - Added `column.summaryCellClass` and `column.summaryFormatter` props + - `column.formatter` isn't used anymore to render summary row cells. + - Only visible headers cells are now rendered. [#1837](https://github.com/Comcast/react-data-grid/pull/1837) + - ⚠️ the `rowKeyGetter` prop is now required for row selection. + - ⚠️ `column.cellClass` does not affect header cells anymore. + - ⚠️ `onScroll` will directly pass the UIEvent rather than the scrollLeft and scrollRight only. + - ⚠️ The stylesheets are now automatically injected, there is no stylsheet to manually import anymore. + +## `main` to `alpha` + +- **Added:** + - TypeScript declaration files + - `column.cellContentRenderer` + - More info in this [gist](https://gist.github.com/nstepien/090298c3c2d94324cb332c33d82fdcfb) + - `summaryRows` prop [#1773](https://github.com/Comcast/react-data-grid/pull/1773) + - `sortColumn` and `sortDirection` props + - ⚠️ The internal sort states have been removed. + - Check [#1768](https://github.com/Comcast/react-data-grid/pull/1768) on how to migrate. + - `selectedRows` and `onSelectedRowsChange` props + - ⚠️ Row selection has been reimplemented. + - A new `SelectColumn` is now available to import and add a row selection column. + - Check [#1762](https://github.com/Comcast/react-data-grid/pull/1762) on how to migrate. +- **Removed:** + - **Packages:** + - `react-data-grid-examples` + - Use the website as reference, or clone the repo locally and run `npm install` + `npm start` + - **Props:** + - ⚠️ `onCellsDragged` + - ⚠️ `onDragHandleDoubleClick` + - ⚠️ `onRows` + - ⚠️ `onRowUpdated` + - ⚠️ `rowScrollTimeout` + - ⚠️ `toolbar` + - Check [#1769](https://github.com/Comcast/react-data-grid/pull/1769) on how to migrate + - ⚠️ `isScrolling` (from `column.formatter` props) + - ⚠️ `ContainerEditorWrapper` + - ⚠️ `EditorBase` + - ⚠️ `setScrollLeft` from `Row` and `Cell` renderers + - `setScrollLeft` instance method was previously required on custom Cell and Row renderers and it can be safely removed now. + - More info in [#1793](https://github.com/Comcast/react-data-grid/pull/1793) + - ⚠️ Dropped ImmutableJS support. + - ⚠️ Dropped dynamic height row support. + - This was not officially supported, but it was still possible to implement dynamic rows via custom Row renderer. This was a buggy feature so it has been removed. + - ⚠️ Removed row reordering support. +- **Renamed:** + - `ReactDataGrid` to `DataGrid` +- **Changed:** + - ⚠️ The stylesheets are now bundled separately: + - `react-data-grid/dist/react-data-grid.css` + - ⚠️ Reimplemented stylesheets, renamed various class names [#1780](https://github.com/Comcast/react-data-grid/pull/1780) + - No longer depends on bootstrap + - Resizing a column now immediately resizes all its cells instead of just its header. + - Improved performance across the board. + +### react-data-grid-addons + +- ⚠️ `react-data-grid-addons` has no default export anymore + - Use `import * as DataGridAddons from 'react-data-grid-addons';` instead +- ⚠️ The stylesheets are now bundled separately: + - `react-data-grid-addons/dist/react-data-grid-addons.css` +- **Removed:** + - ⚠️ `AutoComplete` editor + - ⚠️ `Utils` + +## 5.0.5 (Dec 6, 2018) + +- **Bugfix:** fix: draggable resizing col jumps to right ([1421](https://github.com/Comcast/react-data-grid/pull/1421)) +- **Bugfix:** Cell Tooltip - Focus Issues ([1422](https://github.com/Comcast/react-data-grid/pull/1422)) + +## 6.0.1 (Nov 30, 2018) + +- **Bugfix:** Fix formatter exports ([1409](https://github.com/Comcast/react-data-grid/pull/1409)) + +## 6.0.0 (Nov 30, 2018) + +- **Bugfix:** Fix outside click logic for committing changes ([1404](https://github.com/Comcast/react-data-grid/pull/1404)) +- **TechDebt** Add ESLint Rules ([1396](https://github.com/Comcast/react-data-grid/pull/1396) [1397](https://github.com/Comcast/react-data-grid/pull/1397) [1396](https://github.com/Comcast/react-data-grid/pull/1398) [1399](https://github.com/Comcast/react-data-grid/pull/1399)) +- **TechDebt:** Upgrade build tools to latest versions ([1350](https://github.com/Comcast/react-data-grid/pull/1350)) +- **Feature:** Cleanup zIndex logic ([1393](https://github.com/Comcast/react-data-grid/pull/1393)) +- **Breaking** Use react portals for cell editors ([1369](https://github.com/Comcast/react-data-grid/pull/1369)) +- **TechDebt:** Upgrade build tools to latest versions ([1350](https://github.com/Comcast/react-data-grid/pull/1350)) + +## 5.0.4 (Nov 14, 2018) + +- **Bugfix:** Custom Formatters Example - Styling Fix ([1364](https://github.com/Comcast/react-data-grid/pull/1364)) +- **Bugfix:** Fix website publishing and remove ImmutableJS dependency ([1366](https://github.com/Comcast/react-data-grid/pull/1366)) +- **Bugfix:** Remove react-data-grid dependency from the addons package ([1354](https://github.com/Comcast/react-data-grid/pull/1354)) +- **Bugfix:** Fix drag fill in IE 11 ([1359](https://github.com/Comcast/react-data-grid/pull/1359)) +- **Bugfix:** Ensure webpack uses correct common js external ref ([1370](https://github.com/Comcast/react-data-grid/pull/1370)) +- **Feature:** Move DropTargetRowContainer static styles to CSS class for user customization ([1308](https://github.com/Comcast/react-data-grid/pull/1308)) +- **Bugfix:** Replace use of i for column index which is no longer passed in ([1344](https://github.com/Comcast/react-data-grid/pull/1344)) +- **Bugfix:** Remove utils from documentation as an exported module ([1374](https://github.com/Comcast/react-data-grid/pull/1374)) +- **TechDebt:** Upgrade eslint packages ([1376](https://github.com/Comcast/react-data-grid/pull/1376)) +- **Bugfix:** Cleanup DraggableContainer and fix styles ([1379](https://github.com/Comcast/react-data-grid/pull/1379)) + +## 5.0.3 (Nov 1, 2018) + +- **Bugfix:** Fix frozen-columns source url ([1355](https://github.com/Comcast/react-data-grid/pull/1355)) +- **TechDebt:** Defining the ref callback as a bound method ([1353](https://github.com/Comcast/react-data-grid/pull/1353)) +- **Bugfix:** Fix cell focusing logic ([1352](https://github.com/Comcast/react-data-grid/pull/1352)) +- **Bugfix:** RDG Tree Cell Expand Styling Issues ([1316](https://github.com/Comcast/react-data-grid/pull/1316)) + +## 5.0.2 (Oct 30, 2018) + +- **Bugfix:** Fix grouping example ([1311](https://github.com/Comcast/react-data-grid/pull/1311)) +- **Bugfix:** Remove contain layout css ([1346](https://github.com/Comcast/react-data-grid/pull/1346)) +- **Bugfix:** Preserve window scroll position on cell selection ([1349](https://github.com/Comcast/react-data-grid/pull/1346)) + +## 5.0.1 (Oct 22, 2018) + +### React-Data-Grid + +- **Bugfix:** Fix CopyMask columns ([1289](https://github.com/Comcast/react-data-grid/pull/1272)) + +## 5.0.0 (Oct 22, 2018) + +### React-Data-Grid + +- **Feature:** Improve Cell navigation Performance ([1123](https://github.com/Comcast/react-data-grid/pull/1123)) +- **Feature:** Scrolling improvements ([1254](https://github.com/Comcast/react-data-grid/pull/1254)) +- **Feature:** Remove react-data-grid dependency from react-data-grid-addons bundle ([1272](https://github.com/Comcast/react-data-grid/pull/1272)) + +## 4.0.8 (May 10, 2018) + +### React-Data-Grid + +- **Bugfix:** Fix editor refs ([#1183](https://github.com/Comcast/react-data-grid/pull/1183)) + +## 4.0.7 (April 19, 2018) + +### React-Data-Grid + +- **Feature:** Support `React v16` ([#1116](https://github.com/Comcast/react-data-grid/pull/1116)) +- **Feature:** Set sort column and direction with props ([#649](https://github.com/Comcast/react-data-grid/pull/649)) +- **Bugfix:** Filtering should ignore null values ([#1147](https://github.com/Comcast/react-data-grid/pull/1147)) +- **Bugfix:** Resize column doesnt work on firefox when also draggable ([#1121](https://github.com/Comcast/react-data-grid/pull/1121)) + +### React-Data-Grid-Addons + +- **Breaking:** Migrate to `react-context-menu 2.9.2` ([#1081](https://github.com/Comcast/react-data-grid/pull/1081)) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 4ba0baffd0..0000000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,42 +0,0 @@ -Use [Github issues](https://github.com/adazzle/react-data-grid/issues) for feature requests and bug reports. - -### Tests - -All commits that fix bugs or add features need a test. - -`` Do not merge code without tests.`` - -### Commit Subjects for Public API Changes - -If your patch **changes the API or fixes a bug** please use one of the -following prefixes in your commit subject: - -- `[fixed] ...` -- `[changed] ...` -- `[added] ...` -- `[removed] ...` - -That ensures the subject line of your commit makes it into the -auto-generated changelog. Do not use these tags if your change doesn't -fix a bug and doesn't change the public API. - -Commits with changed, added, or removed, should probably be reviewed by -another collaborator. - -#### When using `[changed]` or `[removed]`... - -Please include an upgrade path with example code in the commit message. -If it doesn't make sense to do this, then it doesn't make sense to use -`[changed]` or `[removed]` :) - -### Docs - -Please update the docs with any API changes, the code and docs should -always be in sync. - -### Development - -- `npm test` will fire up a karma test runner and run tests in Phantom JS -- `npm run debug-test` will fire up a karma test runner and run tests in chrome. This can be used for debugging purposes -- `npm run examples` will load a webpack dev server that will watch -for changes and build the examples diff --git a/LICENSE b/LICENSE index 816ae55b2b..00f9bdff4b 100644 --- a/LICENSE +++ b/LICENSE @@ -1,9 +1,9 @@ The MIT License (MIT) Original work Copyright (c) 2014 Prometheus Research -Modified work Copyright 2015 Adazzle +Modified work Copyright 2015 Comcast -For the original source code please see https://github.com/prometheusresearch/react-grid +For the original source code please see https://github.com/prometheusresearch-archive/react-grid Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 8a9dc22deb..c978c9765e 100644 --- a/README.md +++ b/README.md @@ -1,60 +1,1819 @@ -# React Data Grid -[![Build status](https://ci.appveyor.com/api/projects/status/smciktvlkvp6r8w7/branch/master?svg=true)](https://ci.appveyor.com/project/adazzle/react-data-grid/branch/master)[![Coverage Status](https://coveralls.io/repos/adazzle/react-data-grid/badge.svg?branch=master)](https://coveralls.io/r/adazzle/react-data-grid?branch=master) [![npm version](https://badge.fury.io/js/react-data-grid.svg)](http://badge.fury.io/js/react-data-grid) -![npm dependencies](https://david-dm.org/adazzle/react-data-grid.svg) -[![React Data Grid chat](https://react-data-grid.herokuapp.com/badge.svg)](https://react-data-grid.herokuapp.com/) +# react-data-grid -Excel-like grid component built with React, with editors, keyboard navigation, copy & paste, and the like http://adazzle.github.io/react-data-grid/ -![react-data-grid](https://cloud.githubusercontent.com/assets/1432798/7348812/78063bd6-ecec-11e4-89d5-ffd327721cd7.PNG) +[![npm-badge]][npm-url] +[![type-badge]][npm-url] +[![size-badge]][size-url] +[![codecov-badge]][codecov-url] +[![ci-badge]][ci-url] +[npm-badge]: https://img.shields.io/npm/v/react-data-grid +[npm-url]: https://www.npmjs.com/package/react-data-grid +[size-badge]: https://img.shields.io/bundlephobia/minzip/react-data-grid +[size-url]: https://bundlephobia.com/package/react-data-grid +[type-badge]: https://img.shields.io/npm/types/react-data-grid +[codecov-badge]: https://codecov.io/gh/Comcast/react-data-grid/branch/main/graph/badge.svg?token=cvrRSWiz0Q +[codecov-url]: https://app.codecov.io/gh/Comcast/react-data-grid +[ci-badge]: https://github.com/Comcast/react-data-grid/workflows/CI/badge.svg +[ci-url]: https://github.com/Comcast/react-data-grid/actions -Installation ------------- +The DataGrid component is designed to handle large datasets efficiently while offering a rich set of features for customization and interactivity. + +## Features + +- [React 19.2+](package.json) support +- Evergreen browsers and server-side rendering support +- Tree-shaking support with no external dependencies to keep your bundles slim +- Great performance thanks to virtualization: columns and rows outside the viewport are not rendered +- Strictly typed with TypeScript +- [Keyboard accessibility](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- Light and dark mode support out of the box. +- [Frozen columns](https://comcast.github.io/react-data-grid/#/CommonFeatures): Freeze columns to keep them visible during horizontal scrolling. +- [Column resizing](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- [Multi-column sorting](https://comcast.github.io/react-data-grid/#/CommonFeatures) + - Click on a sortable column header to toggle between its ascending/descending sort order + - Ctrl+Click / Meta+Click to sort an additional column +- [Column spanning](https://comcast.github.io/react-data-grid/#/ColumnSpanning) +- [Column grouping](https://comcast.github.io/react-data-grid/#/ColumnGrouping) +- [Row selection](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- [Row grouping](https://comcast.github.io/react-data-grid/#/RowGrouping) +- [Summary rows](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- [Dynamic row heights](https://comcast.github.io/react-data-grid/#/VariableRowHeight) +- [No rows fallback](https://comcast.github.io/react-data-grid/#/NoRows) +- [Cell formatting](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- [Cell editing](https://comcast.github.io/react-data-grid/#/CommonFeatures) +- [Cell copy / pasting](https://comcast.github.io/react-data-grid/#/AllFeatures) +- [Cell value dragging / filling](https://comcast.github.io/react-data-grid/#/AllFeatures) +- [Customizable Renderers](https://comcast.github.io/react-data-grid/#/CustomizableRenderers) +- Right-to-left (RTL) support. + +## Links + +- [Examples website](https://comcast.github.io/react-data-grid/) + - [Source code](website) +- [Changelog](CHANGELOG.md) +- [Contributing](CONTRIBUTING.md) + +> **Important**
+> `rolldown-vite` by default uses `lightningcss` to minify css which has a [bug minifying light-dark syntax](https://github.com/parcel-bundler/lightningcss/issues/873). You can switch to `esbuild` as a workaround + +```ts +build: { + ...., + cssMinify: 'esbuild' +} +``` + +## Installation + +Install `react-data-grid` using your favorite package manager: + +```sh +npm i react-data-grid +``` + +```sh +pnpm add react-data-grid +``` + +```sh +yarn add react-data-grid +``` ```sh -npm install react-data-grid -# or -bower install react-data-grid +bun add react-data-grid +``` + +Additionally, import the default styles in your application: + +```tsx +import 'react-data-grid/lib/styles.css'; +``` + +`react-data-grid` is published as ECMAScript modules for evergreen browsers, bundlers, and server-side rendering. + +## Getting started + +Here is a basic example of how to use `react-data-grid` in your React application: + +```tsx +import 'react-data-grid/lib/styles.css'; + +import { DataGrid, type Column } from 'react-data-grid'; + +interface Row { + id: number; + title: string; +} + +const columns: readonly Column[] = [ + { key: 'id', name: 'ID' }, + { key: 'title', name: 'Title' } +]; + +const rows: readonly Row[] = [ + { id: 0, title: 'Example' }, + { id: 1, title: 'Demo' } +]; + +function App() { + return ; +} +``` + +## Theming + +Set `--rdg-color-scheme: light/dark` at the `:root` to control the color theme. The light or dark themes can be enforced using the `rdg-light` or `rdg-dark` classes. + +## API Reference + +### Components + +#### `` + +##### DataGridProps + +###### `columns: readonly Column[]` + +An array of column definitions. Each column should have a key and name. See the [`Column`](#columntrow-tsummaryrow) type for all available options. + +:warning: **Performance:** Passing a new `columns` array will trigger a re-render and recalculation for the entire grid. Always memoize this prop using `useMemo` or define it outside the component to avoid unnecessary re-renders. + +###### `rows: readonly R[]` + +An array of rows, the rows data can be of any type. + +:bulb: **Performance:** The grid is optimized for efficient rendering: + +- **Virtualization**: Only visible rows are rendered in the DOM +- **Individual row updates**: Row components are memoized, so updating a single row object will only re-render that specific row, not all rows +- **Array reference matters**: Changing the array reference itself (e.g., `setRows([...rows])`) triggers viewport and layout recalculations, even if the row objects are unchanged +- **Best practice**: When updating rows, create a new array but reuse unchanged row objects. For example: + + ```tsx + // ✅ Good: Only changed row is re-rendered + setRows(rows.map((row, idx) => (idx === targetIdx ? { ...row, updated: true } : row))); + + // ❌ Avoid: Creates new references for all rows, causing all visible rows to re-render + setRows(rows.map((row) => ({ ...row }))); + ``` + +###### `topSummaryRows?: Maybe` + +Rows pinned at the top of the grid for summary purposes. + +###### `bottomSummaryRows?: Maybe` + +Rows pinned at the bottom of the grid for summary purposes. + +###### `rowKeyGetter?: Maybe<(row: R) => K>` + +Function to return a unique key/identifier for each row. `rowKeyGetter` is required for row selection to work. + +```tsx +import { DataGrid } from 'react-data-grid'; + +interface Row { + id: number; + name: string; +} + +function rowKeyGetter(row: Row) { + return row.id; +} + +function MyGrid() { + return ; +} +``` + +:bulb: While optional, setting this prop is recommended for optimal performance as the returned value is used to set the `key` prop on the row elements. + +:warning: **Performance:** Define this function outside your component or memoize it with `useCallback` to prevent unnecessary re-renders. + +###### `onRowsChange?: Maybe<(rows: R[], data: RowsChangeData) => void>` + +Callback triggered when rows are changed. + +The first parameter is a new rows array with both the updated rows and the other untouched rows. +The second parameter is an object with an `indexes` array highlighting which rows have changed by their index, and the `column` where the change happened. + +```tsx +import { useState } from 'react'; +import { DataGrid } from 'react-data-grid'; + +function MyGrid() { + const [rows, setRows] = useState(initialRows); + + return ; +} +``` + +###### `rowHeight?: Maybe number)>` + +**Default:** `35` pixels + +Height of each row in pixels. A function can be used to set different row heights. + +:warning: **Performance:** When using a function, the height of all rows is calculated upfront on every render. For large datasets (1000+ rows), this can cause performance issues. Consider using a fixed height when possible, or memoize the `rowHeight` function. + +###### `headerRowHeight?: Maybe` + +**Default:** `35` pixels + +Height of the header row in pixels. + +###### `summaryRowHeight?: Maybe` + +**Default:** `35` pixels + +Height of each summary row in pixels. + +###### `columnWidths?: Maybe` + +A map of column widths containing both measured and resized widths. If not provided then an internal state is used. + +```tsx +const [columnWidths, setColumnWidths] = useState((): ColumnWidths => new Map()); + +function addNewRow() { + setRows(...); + // reset column widths after adding a new row + setColumnWidths(new Map()); +} + +return +``` + +###### `onColumnWidthsChange?: Maybe<(columnWidths: ColumnWidths) => void>` + +Callback triggered when column widths change. If not provided then an internal state is used. + +###### `selectedRows?: Maybe>` + +A set of selected row keys. `rowKeyGetter` is required for row selection to work. + +###### `isRowSelectionDisabled?: Maybe<(row: NoInfer) => boolean>` + +Function to determine if row selection is disabled for a specific row. + +###### `onSelectedRowsChange?: Maybe<(selectedRows: Set) => void>` + +Callback triggered when the selection changes. + +```tsx +import { useState } from 'react'; +import { DataGrid, SelectColumn } from 'react-data-grid'; + +const rows: readonly Rows[] = [...]; + +const columns: readonly Column[] = [ + SelectColumn, + // other columns +]; + +function rowKeyGetter(row: Row) { + return row.id; +} + +function isRowSelectionDisabled(row: Row) { + return !row.isActive; +} + +function MyGrid() { + const [selectedRows, setSelectedRows] = useState((): ReadonlySet => new Set()); + + return ( + + ); +} +``` + +###### `sortColumns?: Maybe` + +An array of sorted columns. + +###### `onSortColumnsChange?: Maybe<(sortColumns: SortColumn[]) => void>` + +Callback triggered when sorting changes. + +```tsx +import { useState } from 'react'; +import { DataGrid, SelectColumn } from 'react-data-grid'; + +const rows: readonly Rows[] = [...]; + +const columns: readonly Column[] = [ + { + key: 'name', + name: 'Name', + sortable: true + }, + // other columns +]; + +function MyGrid() { + const [sortColumns, setSortColumns] = useState([]); + + return ( + + ); +} +``` + +More than one column can be sorted via `ctrl (command) + click`. To disable multiple column sorting, change the `onSortColumnsChange` function to + +```tsx +function onSortColumnsChange(sortColumns: SortColumn[]) { + setSortColumns(sortColumns.slice(-1)); +} +``` + +###### `defaultColumnOptions?: Maybe>` + +Default options applied to all columns. + +```tsx +function MyGrid() { + return ( + + ); +} +``` + +###### `onFill?: Maybe<(event: FillEvent) => R>` + +###### `onCellMouseDown: Maybe<(args: CellMouseArgs, event: CellMouseEvent) => void>` + +Callback triggered when a pointer becomes active in a cell. The default behavior is to select the cell. Call `preventGridDefault` to prevent the default behavior. + +```tsx +function onCellMouseDown(args: CellMouseDownArgs, event: CellMouseEvent) { + if (args.column.key === 'id') { + event.preventGridDefault(); + } +} + +; +``` + +###### `onCellClick?: Maybe<(args: CellMouseArgs, event: CellMouseEvent) => void>` + +Callback triggered when a cell is clicked. + +```tsx +function onCellClick(args: CellMouseArgs, event: CellMouseEvent) { + if (args.column.key === 'id') { + event.preventGridDefault(); + } +} + +; +``` + +This event can be used to open cell editor on single click + +```tsx +function onCellClick(args: CellMouseArgs, event: CellMouseEvent) { + if (args.column.key === 'id') { + args.selectCell(true); + } +} +``` + +###### `onCellDoubleClick?: Maybe<(args: CellMouseArgs, event: CellMouseEvent) => void>` + +Callback triggered when a cell is double-clicked. The default behavior is to open the editor if the cell is editable. Call `preventGridDefault` to prevent the default behavior. + +```tsx +function onCellDoubleClick(args: CellMouseArgs, event: CellMouseEvent) { + if (args.column.key === 'id') { + event.preventGridDefault(); + } +} + +; +``` + +###### `onCellContextMenu?: Maybe<(args: CellMouseArgs, event: CellMouseEvent) => void>` + +Callback triggered when a cell is right-clicked. + +```tsx +function onCellContextMenu(args: CellMouseArgs, event: CellMouseEvent) { + if (args.column.key === 'id') { + event.preventDefault(); + // open custom context menu + } +} + +; +``` + +###### `onCellKeyDown?: Maybe<(args: CellKeyDownArgs, event: CellKeyboardEvent) => void>` + +A function called when keydown event is triggered on a cell. This event can be used to customize cell navigation and editing behavior. + +**Examples** + +- Prevent editing on `Enter` + +```tsx +function onCellKeyDown(args: CellKeyDownArgs, event: CellKeyboardEvent) { + if (args.mode === 'SELECT' && event.key === 'Enter') { + event.preventGridDefault(); + } +} +``` + +- Prevent navigation on `Tab` + +```tsx +function onCellKeyDown(args: CellKeyDownArgs, event: CellKeyboardEvent) { + if (args.mode === 'SELECT' && event.key === 'Tab') { + event.preventGridDefault(); + } +} +``` + +Check [more examples](website/routes/CellNavigation.tsx) + +###### `onCellCopy?: Maybe<(args: CellCopyArgs, NoInfer>, event: CellClipboardEvent) => void>` + +Callback triggered when a cell's content is copied. + +###### `onCellPaste?: Maybe<(args: CellPasteArgs, NoInfer>, event: CellClipboardEvent) => void>` + +Callback triggered when content is pasted into a cell. + +###### `onSelectedCellChange?: Maybe<(args: CellSelectArgs) => void>;` + +Triggered when the selected cell is changed. + +Arguments: + +- `args.rowIdx`: `number` - row index +- `args.row`: `R` - row object of the currently selected cell +- `args.column`: `CalculatedColumn` - column object of the currently selected cell + +###### `onScroll?: Maybe<(event: React.UIEvent) => void>` + +Callback triggered when the grid is scrolled. + +###### `onColumnResize?: Maybe<(column: CalculatedColumn, width: number) => void>` + +Callback triggered when column is resized. + +###### `onColumnsReorder?: Maybe<(sourceColumnKey: string, targetColumnKey: string) => void>` + +Callback triggered when columns are reordered. + +###### `enableVirtualization?: Maybe` + +**Default:** `true` + +This prop can be used to disable virtualization. + +###### `renderers?: Maybe>` + +Custom renderers for cells, rows, and other components. + +```tsx +interface Renderers { + renderCell?: Maybe<(key: Key, props: CellRendererProps) => ReactNode>; + renderCheckbox?: Maybe<(props: RenderCheckboxProps) => ReactNode>; + renderRow?: Maybe<(key: Key, props: RenderRowProps) => ReactNode>; + renderSortStatus?: Maybe<(props: RenderSortStatusProps) => ReactNode>; + noRowsFallback?: Maybe; +} +``` + +For example, the default `` component can be wrapped via the `renderRow` prop to add contexts or tweak props + +```tsx +import { DataGrid, RenderRowProps, Row } from 'react-data-grid'; + +function myRowRenderer(key: React.Key, props: RenderRowProps) { + return ( + + + + ); +} + +function MyGrid() { + return ; +} +``` + +###### `rowClass?: Maybe<(row: R, rowIdx: number) => Maybe>` + +Function to apply custom class names to rows. + +```tsx +import { DataGrid } from 'react-data-grid'; + +function MyGrid() { + return ; +} + +function rowClass(row: Row, rowIdx: number) { + return rowIdx % 2 === 0 ? 'even' : 'odd'; +} +``` + +:warning: **Performance:** Define this function outside your component or memoize it with `useCallback` to avoid re-rendering all rows on every render. + +###### `headerRowClass?: Maybe>` + +Custom class name for the header row. + +###### `direction?: Maybe<'ltr' | 'rtl'>` + +This property sets the text direction of the grid, it defaults to `'ltr'` (left-to-right). Setting `direction` to `'rtl'` has the following effects: + +- Columns flow from right to left +- Frozen columns are pinned on the right +- Column resize cursor is shown on the left edge of the column +- Scrollbar is moved to the left + +###### `className?: string | undefined` + +Custom class name for the grid. + +###### `style?: CSSProperties | undefined` + +Custom styles for the grid. + +###### `'aria-label'?: string | undefined` + +The label of the grid. We recommend providing a label using `aria-label` or `aria-labelledby` + +###### `'aria-labelledby'?: string | undefined` + +The id of the element containing a label for the grid. We recommend providing a label using `aria-label` or `aria-labelledby` + +###### `'aria-description'?: string | undefined` + +###### `'aria-describedby'?: string | undefined` + +If the grid has a caption or description, `aria-describedby` can be set on the grid element with a value referring to the element containing the description. + +###### `'data-testid'?: Maybe` + +This prop can be used to add a testid for testing. We recommend querying the grid by by its `role` and `name`. + +```tsx +function MyGrid() { + return ; +} + +test('grid', async () => { + await render(); + const grid = screen.getByRole('grid', { name: 'my-grid' }); +}); +``` + +#### `` + +`TreeDataGrid` is a component built on top of `DataGrid` to add hierarchical row grouping. This implements the [Treegrid pattern](https://www.w3.org/WAI/ARIA/apg/patterns/treegrid/). + +**How it works:** + +1. The `groupBy` prop specifies which columns should be used for grouping +2. The `rowGrouper` function groups rows by the specified column keys +3. Group rows are rendered with expand/collapse toggles +4. Child rows are nested under their parent groups +5. Groups can be expanded/collapsed by clicking the toggle or using keyboard navigation (, ) + +**Keyboard Navigation:** + +- (Right Arrow): Expand a collapsed group row when focused +- (Left Arrow): Collapse an expanded group row when focused, or navigate to parent group + +**Unsupported Props:** + +The following `DataGrid` props are not supported in `TreeDataGrid`: + +- `onFill` - Drag-fill is disabled for tree grids +- `isRowSelectionDisabled` - Row selection disabling is not available + +**Caveats:** + +- Group columns cannot be rendered under one column +- Group columns are automatically frozen and cannot be unfrozen +- Cell copy/paste does not work on group rows + +##### TreeDataGridProps + +All [`DataGridProps`](#datagridprops) are supported except those listed above, plus the following additional props: + +###### `groupBy: readonly string[]` + +**Required.** An array of column keys to group by. The order determines the grouping hierarchy (first key is the top level, second key is nested under the first, etc.). + +```tsx +import { TreeDataGrid, type Column } from 'react-data-grid'; + +interface Row { + id: number; + country: string; + city: string; + name: string; +} + +const columns: readonly Column[] = [ + { key: 'country', name: 'Country' }, + { key: 'city', name: 'City' }, + { key: 'name', name: 'Name' } +]; + +function MyGrid() { + return ( + + ); +} +``` + +###### `rowGrouper: (rows: readonly R[], columnKey: string) => Record` + +**Required.** A function that groups rows by the specified column key. Returns an object where keys are the group values and values are arrays of rows belonging to that group. + +```tsx +function rowGrouper(rows: Row[], columnKey: string) { + return Object.groupBy(rows, (row) => row[columnKey]); +} +``` + +###### `expandedGroupIds: ReadonlySet` + +**Required.** A set of group IDs that are currently expanded. Group IDs are generated by `groupIdGetter`. + +```tsx +import { useState } from 'react'; +import { TreeDataGrid } from 'react-data-grid'; + +function MyGrid() { + const [expandedGroupIds, setExpandedGroupIds] = useState((): ReadonlySet => new Set()); + + return ( + + ); +} +``` + +###### `onExpandedGroupIdsChange: (expandedGroupIds: Set) => void` + +**Required.** Callback triggered when groups are expanded or collapsed. + +###### `groupIdGetter?: Maybe<(groupKey: string, parentId?: string) => string>` + +Function to generate unique IDs for group rows. If not provided, a default implementation is used that concatenates parent and group keys with `__`. + +###### `rowHeight?: Maybe) => number)>` + +**Note:** Unlike `DataGrid`, the `rowHeight` function receives [`RowHeightArgs`](#rowheightargstrow) which includes a `type` property to distinguish between regular rows and group rows: + +```tsx +function getRowHeight(args: RowHeightArgs): number { + if (args.type === 'GROUP') { + return 50; // Custom height for group rows + } + return 35; // Height for regular rows +} + + ``` -This library is written with CommonJS modules. If you are using -browserify, webpack, or similar, you can consume it like anything else -installed from npm. +#### `` + +The default row component. Can be wrapped via the `renderers.renderRow` prop. + +##### Props + +[`RenderRowProps`](#renderrowpropstrow-tsummaryrow) + +#### `` + +The default cell component. Can be wrapped via the `renderers.renderCell` prop. + +##### Props + +[`CellRendererProps`](#cellrendererpropstrow-tsummaryrow) + +#### `` + +A formatter component for rendering row selection checkboxes. + +##### Props + +###### `value: boolean` + +Whether the checkbox is checked. + +###### `tabIndex: number` + +The tab index for keyboard navigation. -There is also a global build available on bower, find the library on -`window.ReactDataGrid`. +###### `disabled?: boolean | undefined` +Whether the checkbox is disabled. -Overview --------- +###### `onChange: (value: boolean, isShiftClick: boolean) => void` -ReactDataGrid is an advanced JavaScript spreadsheet component built using React +Callback when the checkbox state changes. -Features --------- +###### `onClick?: MouseEventHandler | undefined` -- Lightning fast virtual rendering -- [Can render hundreds of thousands of rows with no lag](http://adazzle.github.io/react-data-grid/examples.html#/million-rows) -- Keyboard navigation -- [Fully editable grid](http://adazzle.github.io/react-data-grid/examples.html#/editable) -- [Rich cell editors like autocomplete, checkbox and dropdown editors, complete with keyboard navigation](http://adazzle.github.io/react-data-grid/examples.html#/editors) -- Custom cell Editors - Easily create your own -- [Custom cell Formatters](http://adazzle.github.io/react-data-grid/examples.html#/formatters) -- [Frozen columns](http://adazzle.github.io/react-data-grid/examples.html#/fixed) -- [Resizable columns](http://adazzle.github.io/react-data-grid/examples.html#/resizable) -- [Sorting](http://adazzle.github.io/react-data-grid/examples.html#/sortable) -- [Filtering] (http://adazzle.github.io/react-data-grid/examples.html#/filterable) -- Copy and Paste values into other cells -- Multiple cell updates using cell dragdown +Optional click handler. +###### `'aria-label'?: string | undefined` -Check out the `examples` directory to see how simple previously complex UI -and workflows are to create. +Accessible label for the checkbox. -Contributing ------------- +###### `'aria-labelledby'?: string | undefined` + +ID of the element that labels the checkbox. + +### Hooks + +#### `useHeaderRowSelection()` + +Hook for managing header row selection state. Used within custom header cell renderers to implement custom "select all" functionality. + +**Returns:** + +- `isIndeterminate: boolean` - Whether some (but not all) rows are selected +- `isRowSelected: boolean` - Whether all rows are selected +- `onRowSelectionChange: (event: SelectHeaderRowEvent) => void` - Callback to change selection state + +**Example:** + +```tsx +function CustomHeaderCell() { + const { isIndeterminate, isRowSelected, onRowSelectionChange } = useHeaderRowSelection(); + + return ( + onRowSelectionChange({ checked: event.target.checked })} + /> + ); +} +``` + +#### `useRowSelection()` + +Hook for managing row selection state. Used within custom cell renderers to implement custom row selection. + +**Returns:** + +- `isRowSelectionDisabled: boolean` - Whether selection is disabled for this row +- `isRowSelected: boolean` - Whether this row is selected +- `onRowSelectionChange: (event: SelectRowEvent) => void` - Callback to change selection state + +**Example:** + +```tsx +function CustomSelectCell({ row }: RenderCellProps) { + const { isRowSelectionDisabled, isRowSelected, onRowSelectionChange } = useRowSelection(); + + return ( + + onRowSelectionChange({ + row, + checked: event.target.checked, + isShiftClick: event.nativeEvent.shiftKey + }) + } + /> + ); +} +``` + +### Render Functions + +#### `renderHeaderCell(props: RenderHeaderCellProps)` + +The default header cell renderer. Renders sortable columns with sort indicators. + +**Example:** + +```tsx +import { renderHeaderCell, type Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'name', + name: 'Name', + sortable: true, + renderHeaderCell + } +]; +``` + +#### `renderTextEditor(props: RenderEditCellProps)` + +A basic text editor provided for convenience. + +**Example:** + +```tsx +import { renderTextEditor, type Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'title', + name: 'Title', + renderEditCell: renderTextEditor + } +]; +``` + +#### `renderSortIcon(props: RenderSortIconProps)` + +Renders the sort direction arrow icon. + +**Props:** + +- `sortDirection: SortDirection | undefined` - 'ASC', 'DESC', or undefined + +#### `renderSortPriority(props: RenderSortPriorityProps)` + +Renders the sort priority number for multi-column sorting. + +**Props:** + +- `priority: number | undefined` - The sort priority (1, 2, 3, etc.) + +#### `renderCheckbox(props: RenderCheckboxProps)` + +Renders a checkbox input with proper styling and accessibility. + +**Props:** + +- `checked: boolean` - Whether the checkbox is checked +- `indeterminate?: boolean` - Whether the checkbox is in indeterminate state +- `disabled?: boolean` - Whether the checkbox is disabled +- `onChange: (checked: boolean, shift: boolean) => void` - Change handler +- `tabIndex: number` - Tab index for keyboard navigation +- `aria-label?: string` - Accessible label +- `aria-labelledby?: string` - ID of labeling element + +**Example:** + +```tsx +import { DataGrid, renderCheckbox } from 'react-data-grid'; + + renderCheckbox({ ...props, 'aria-label': 'Select row' }) + }} +/>; +``` + +#### `renderToggleGroup(props: RenderGroupCellProps)` + +The default group cell renderer used by the columns used for grouping (`groupBy` prop). This renders the expand/collapse toggle. + +##### Props + +[`RenderGroupCellProps`](#rendergroupcellpropstrow-tsummaryrow) + +**Example:** + +```tsx +import { renderToggleGroup, type Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'group', + name: 'Group', + renderGroupCell: renderToggleGroup + } +]; +``` + +#### `renderValue(props: RenderCellProps)` + +The default cell renderer that renders the value of `row[column.key]`. + +**Example:** + +```tsx +import { renderValue, type Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'title', + name: 'Title', + renderCell: renderValue + } +]; +``` + +### Context + +#### `DataGridDefaultRenderersContext` + +Context for providing default renderers to DataGrids in your app. + +**Example:** + +```tsx +import { DataGridDefaultRenderersContext, type Renderers } from 'react-data-grid'; + +// custom implementations of renderers +const defaultGridRenderers: Renderers = { + renderCheckbox, + renderSortStatus +}; + +function AppProvider({ children }) { + return ( + + {children} + + ); +} +``` + +### Other + +#### `SelectColumn: Column` + +A pre-configured column for row selection. +Includes checkbox renderers for header, regular rows, and grouped rows. + +**Example:** + +```tsx +import { DataGrid, SelectColumn, type Column } from 'react-data-grid'; + +const columns: readonly Column[] = [SelectColumn, ...otherColumns]; + +function rowKeyGetter(row: Row) { + return row.id; +} + +function MyGrid() { + return ( + + ); +} +``` + +#### `SELECT_COLUMN_KEY = 'rdg-select-column'` + +The key used for the `SelectColumn`. Useful for identifying or filtering the select column. + +**Example:** + +```tsx +import { SELECT_COLUMN_KEY } from 'react-data-grid'; + +const nonSelectColumns = columns.filter((column) => column.key !== SELECT_COLUMN_KEY); +``` + +### Types + +#### `Column` + +Defines the configuration for a column in the grid. + +##### `name: string | ReactElement` + +The name of the column. Displayed in the header cell by default. + +##### `key: string` + +A unique key to distinguish each column + +##### `width?: Maybe` + +**Default** `auto` + +Width can be any valid css grid column value. If not specified, it will be determined automatically based on grid width and specified widths of other columns. + +```tsx +width: 80, // pixels +width: '25%', +width: 'max-content', +width: 'minmax(100px, max-content)', +``` + +`max-content` can be used to expand the column to show all the content. Note that the grid is only able to calculate column width for visible rows. + +##### `minWidth?: Maybe` + +**Default**: `50` pixels + +Minimum column width in pixels. + +##### `maxWidth?: Maybe` + +Maximum column width in pixels. + +##### `cellClass?: Maybe Maybe)>` + +Class name(s) for cells. Can be a string or a function that returns a class name based on the row. + +##### `headerCellClass?: Maybe` + +Class name(s) for the header cell. + +##### `summaryCellClass?: Maybe Maybe)>` + +Class name(s) for summary cells. Can be a string or a function that returns a class name based on the summary row. + +##### `renderCell?: Maybe<(props: RenderCellProps) => ReactNode>` + +Render function to render the content of cells. + +##### `renderHeaderCell?: Maybe<(props: RenderHeaderCellProps) => ReactNode>` + +Render function to render the content of the header cell. + +##### `renderSummaryCell?: Maybe<(props: RenderSummaryCellProps) => ReactNode>` + +Render function to render the content of summary cells + +##### `renderGroupCell?: Maybe<(props: RenderGroupCellProps) => ReactNode>` + +Render function to render the content of group cells when using `TreeDataGrid`. + +##### `renderEditCell?: Maybe<(props: RenderEditCellProps) => ReactNode>` + +Render function to render the content of edit cells. When set, the column is automatically set to be editable + +##### `editable?: Maybe boolean)>` + +Control whether cells can be edited with `renderEditCell`. + +##### `colSpan?: Maybe<(args: ColSpanArgs) => Maybe>` + +Function to determine how many columns this cell should span. Returns the number of columns to span, or `undefined` for no spanning. See the `ColSpanArgs` type in the Types section below. + +**Example:** + +```tsx +import type { Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'title', + name: 'Title', + colSpan(args) { + if (args.type === 'ROW' && args.row.isFullWidth) { + return 5; // Span 5 columns for full-width rows + } + return undefined; + } + } +]; +``` + +##### `frozen?: Maybe` + +**Default**: `false` + +Determines whether column is frozen. Frozen columns are pinned on the left. At the moment we do not support pinning columns on the right. + +##### `resizable?: Maybe` + +**Default**: `false` + +Enable resizing of the column + +##### `sortable?: Maybe` + +**Default**: `false` + +Enable sorting of the column + +##### `draggable?: Maybe` + +**Default**: `false` + +Enable dragging of the column + +##### `sortDescendingFirst?: Maybe` + +**Default**: `false` + +Sets the column sort order to be descending instead of ascending the first time the column is sorted + +##### `editorOptions` + +Options for cell editing. + +###### `displayCellContent?: Maybe` + +**Default**: `false` + +Render the cell content in addition to the edit cell content. Enable this option when the editor is rendered outside the grid, like a modal for example. + +###### `commitOnOutsideClick?: Maybe` + +**Default**: `true` + +Commit changes when clicking outside the cell. + +###### `closeOnExternalRowChange?: Maybe` + +**Default**: `true` + +Close the editor when the row value changes externally. + +#### `ColumnGroup` + +Defines a group of columns that share a common header. + +```tsx +interface ColumnGroup { + readonly name: string | ReactElement; + readonly headerCellClass?: Maybe; + readonly children: readonly ColumnOrColumnGroup[]; +} +``` + +**Example:** + +```tsx +import type { ColumnOrColumnGroup } from 'react-data-grid'; + +const columns: readonly ColumnOrColumnGroup[] = [ + { + name: 'Personal Info', + children: [ + { key: 'firstName', name: 'First Name' }, + { key: 'lastName', name: 'Last Name' } + ] + } +]; +``` + +#### `ColumnOrColumnGroup` + +Union type representing either a `Column` or a `ColumnGroup`. + +#### `CalculatedColumn` + +Extends `Column` with additional computed properties used internally by the grid. This is the type passed to render functions. + +**Additional properties:** + +- `idx: number` - The column index +- `level: number` - Nesting level when using column groups +- `parent: CalculatedColumnParent | undefined` - Parent column group if nested +- Multiple Column properties have their values set to their default value + +#### `CalculatedColumnParent` + +Represents a parent column group in the calculated column structure. + +```tsx +interface CalculatedColumnParent { + readonly name: string | ReactElement; + readonly parent: CalculatedColumnParent | undefined; + readonly idx: number; + readonly colSpan: number; + readonly level: number; + readonly headerCellClass?: Maybe; +} +``` + +#### `CalculatedColumnOrColumnGroup` + +Union type representing either a `CalculatedColumnParent` or a `CalculatedColumn`. + +```tsx +type CalculatedColumnOrColumnGroup = CalculatedColumnParent | CalculatedColumn; +``` + +#### `RowHeightArgs` + +Arguments passed to the `rowHeight` function when it's a function. + +```tsx +type RowHeightArgs = { type: 'ROW'; row: TRow } | { type: 'GROUP'; row: GroupRow }; +``` + +**Example:** + +```tsx +function getRowHeight(args: RowHeightArgs): number { + if (args.type === 'GROUP') { + return 40; + } + return args.row.isLarge ? 60 : 35; +} + + +``` + +#### `RenderCellProps` + +Props passed to custom cell renderers. + +```tsx +interface RenderCellProps { + column: CalculatedColumn; + row: TRow; + rowIdx: number; + isCellEditable: boolean; + tabIndex: number; + onRowChange: (row: TRow) => void; +} +``` + +**Example:** + +```tsx +import type { RenderCellProps } from 'react-data-grid'; + +function renderCell({ row, column, onRowChange }: RenderCellProps) { + return ( +
+ {row[column.key]} + +
+ ); +} +``` + +#### `RenderHeaderCellProps` + +Props passed to custom header cell renderers. + +```tsx +interface RenderHeaderCellProps { + column: CalculatedColumn; + sortDirection: SortDirection | undefined; + priority: number | undefined; + tabIndex: number; +} +``` + +#### `RenderEditCellProps` + +Props passed to custom edit cell renderers (editors). + +```tsx +interface RenderEditCellProps { + column: CalculatedColumn; + row: TRow; + rowIdx: number; + onRowChange: (row: TRow, commitChanges?: boolean) => void; + onClose: (commitChanges?: boolean, shouldFocusCell?: boolean) => void; +} +``` + +**Example:** + +```tsx +import type { RenderEditCellProps } from 'react-data-grid'; + +function CustomEditor({ row, column, onRowChange, onClose }: RenderEditCellProps) { + return ( + onRowChange({ ...row, [column.key]: event.target.value })} + onBlur={() => onClose(true)} + /> + ); +} +``` + +#### `RenderSummaryCellProps` + +Props passed to summary cell renderers. + +```tsx +interface RenderSummaryCellProps { + column: CalculatedColumn; + row: TSummaryRow; + tabIndex: number; +} +``` + +#### `RenderGroupCellProps` + +Props passed to group cell renderers when using `TreeDataGrid`. + +```tsx +interface RenderGroupCellProps { + groupKey: unknown; + column: CalculatedColumn; + row: GroupRow; + childRows: readonly TRow[]; + isExpanded: boolean; + tabIndex: number; + toggleGroup: () => void; +} +``` + +#### `RenderRowProps` + +Props passed to custom row renderers. + +```tsx +interface RenderRowProps { + row: TRow; + viewportColumns: readonly CalculatedColumn[]; + rowIdx: number; + selectedCellIdx: number | undefined; + isRowSelected: boolean; + isRowSelectionDisabled: boolean; + gridRowStart: number; + lastFrozenColumnIndex: number; + draggedOverCellIdx: number | undefined; + selectedCellEditor: ReactElement> | undefined; + onRowChange: (column: CalculatedColumn, rowIdx: number, newRow: TRow) => void; + rowClass: Maybe<(row: TRow, rowIdx: number) => Maybe>; + // ... and event handlers +} +``` + +#### `CellRendererProps` + +Props passed to the cell renderer when using `renderers.renderCell`. + +Extends `RenderRowProps` with cell-specific properties like `column`, `colSpan`, `isCellSelected`, etc. + +#### `Renderers` + +Custom renderer configuration for the grid. + +```tsx +interface Renderers { + renderCell?: Maybe<(key: Key, props: CellRendererProps) => ReactNode>; + renderCheckbox?: Maybe<(props: RenderCheckboxProps) => ReactNode>; + renderRow?: Maybe<(key: Key, props: RenderRowProps) => ReactNode>; + renderSortStatus?: Maybe<(props: RenderSortStatusProps) => ReactNode>; + noRowsFallback?: Maybe; +} +``` + +#### `CellMouseArgs` + +Arguments passed to cell mouse event handlers. + +```tsx +interface CellMouseArgs { + column: CalculatedColumn; + row: TRow; + rowIdx: number; + selectCell: (enableEditor?: boolean) => void; +} +``` + +##### `column: CalculatedColumn` + +The column object of the cell. + +##### `row: TRow` + +The row object of the cell. + +##### `rowIdx: number` + +The row index of the cell. + +##### `selectCell: (enableEditor?: boolean) => void` + +Function to manually select the cell. Pass `true` to immediately start editing. + +**Example:** + +```tsx +import type { CellMouseArgs, CellMouseEvent } from 'react-data-grid'; + +function onCellClick(args: CellMouseArgs, event: CellMouseEvent) { + console.log('Clicked cell at row', args.rowIdx, 'column', args.column.key); + args.selectCell(true); // Select and start editing +} +``` + +#### `CellMouseEvent` + +Extends `React.MouseEvent` with grid-specific methods. + +##### `event.preventGridDefault(): void` + +Prevents the default grid behavior for this event. + +##### `event.isGridDefaultPrevented(): boolean` + +Returns whether `preventGridDefault` was called. + +**Example:** + +```tsx +import type { CellMouseArgs, CellMouseEvent } from 'react-data-grid'; + +function onCellClick(args: CellMouseArgs, event: CellMouseEvent) { + if (args.column.key === 'actions') { + event.preventGridDefault(); // Prevent cell selection + } +} +``` + +#### `CellKeyboardEvent` + +Extends `React.KeyboardEvent` with grid-specific methods. + +##### `event.preventGridDefault(): void` + +Prevents the default grid behavior for this keyboard event. + +##### `event.isGridDefaultPrevented(): boolean` + +Returns whether `preventGridDefault` was called. + +#### `CellClipboardEvent` + +Type alias for `React.ClipboardEvent`. Used for copy and paste events. + +```tsx +type CellClipboardEvent = React.ClipboardEvent; +``` + +#### `CellKeyDownArgs` + +Arguments passed to the `onCellKeyDown` handler. The shape differs based on whether the cell is in SELECT or EDIT mode. + +**SELECT mode:** + +```tsx +interface SelectCellKeyDownArgs { + mode: 'SELECT'; + column: CalculatedColumn; + row: TRow; + rowIdx: number; + selectCell: (position: Position, options?: SelectCellOptions) => void; +} +``` + +**EDIT mode:** + +```tsx +interface EditCellKeyDownArgs { + mode: 'EDIT'; + column: CalculatedColumn; + row: TRow; + rowIdx: number; + navigate: () => void; + onClose: (commitChanges?: boolean, shouldFocusCell?: boolean) => void; +} +``` + +**Example:** + +```tsx +import type { CellKeyboardEvent, CellKeyDownArgs } from 'react-data-grid'; + +function onCellKeyDown(args: CellKeyDownArgs, event: CellKeyboardEvent) { + if (args.mode === 'EDIT' && event.key === 'Escape') { + args.onClose(false); // Close without committing + event.preventGridDefault(); + } +} +``` + +#### `CellSelectArgs` + +Arguments passed to `onSelectedCellChange`. + +```tsx +interface CellSelectArgs { + rowIdx: number; + row: TRow | undefined; + column: CalculatedColumn; +} +``` + +#### `CellCopyArgs` + +Arguments passed to `onCellCopy`. + +```tsx +interface CellCopyArgs { + column: CalculatedColumn; + row: TRow; +} +``` + +#### `CellPasteArgs` + +Arguments passed to `onCellPaste`. + +```tsx +interface CellPasteArgs { + column: CalculatedColumn; + row: TRow; +} +``` + +#### `ColSpanArgs` + +Arguments passed to the `colSpan` function. + +```tsx +type ColSpanArgs = + | { type: 'HEADER' } + | { type: 'ROW'; row: TRow } + | { type: 'SUMMARY'; row: TSummaryRow }; +``` + +**Example:** + +```tsx +import type { Column } from 'react-data-grid'; + +const columns: readonly Column[] = [ + { + key: 'title', + name: 'Title', + colSpan(args) { + if (args.type === 'ROW' && args.row.isFullWidth) { + return 3; // Span 3 columns + } + return undefined; + } + } +]; +``` + +#### `SortColumn` + +Describes a sorted column. + +```tsx +interface SortColumn { + readonly columnKey: string; + readonly direction: SortDirection; +} +``` + +#### `SortDirection` + +```tsx +type SortDirection = 'ASC' | 'DESC'; +``` + +#### `RowsChangeData` + +Data provided to `onRowsChange` callback. + +```tsx +interface RowsChangeData { + indexes: number[]; + column: CalculatedColumn; +} +``` + +- `indexes`: Array of row indexes that changed +- `column`: The column where changes occurred + +#### `SelectRowEvent` + +Event object for row selection changes. + +```tsx +interface SelectRowEvent { + row: TRow; + checked: boolean; + isShiftClick: boolean; +} +``` + +#### `SelectHeaderRowEvent` + +Event object for header row selection changes. + +```tsx +interface SelectHeaderRowEvent { + checked: boolean; +} +``` + +#### `FillEvent` + +Event object for drag-fill operations. + +```tsx +interface FillEvent { + columnKey: string; + sourceRow: TRow; + targetRow: TRow; +} +``` + +Used with the `onFill` prop to handle cell value dragging. + +#### `GroupRow` + +Represents a grouped row in `TreeDataGrid`. + +```tsx +interface GroupRow { + readonly childRows: readonly TRow[]; + readonly id: string; + readonly parentId: unknown; + readonly groupKey: unknown; + readonly isExpanded: boolean; + readonly level: number; + readonly posInSet: number; + readonly setSize: number; + readonly startRowIndex: number; +} +``` + +#### `ColumnWidths` + +A map of column widths. + +```tsx +type ColumnWidths = ReadonlyMap; + +interface ColumnWidth { + readonly type: 'resized' | 'measured'; + readonly width: number; +} +``` + +Used with `columnWidths` and `onColumnWidthsChange` props to control column widths externally. + +#### `Position` + +Represents a cell position in the grid. + +```tsx +interface Position { + readonly idx: number; // Column index + readonly rowIdx: number; // Row index +} +``` + +#### `SelectCellOptions` + +Options for programmatically selecting a cell. + +```tsx +interface SelectCellOptions { + enableEditor?: Maybe; + shouldFocusCell?: Maybe; +} +``` + +#### `RenderCheckboxProps` + +Props for custom checkbox renderers. + +```tsx +interface RenderCheckboxProps { + checked: boolean; + indeterminate?: boolean; + disabled?: boolean; + onChange: (checked: boolean, shift: boolean) => void; + tabIndex: number; + 'aria-label'?: string; + 'aria-labelledby'?: string; +} +``` + +#### `RenderSortStatusProps` + +Props for custom sort status renderers. + +```tsx +interface RenderSortStatusProps { + sortDirection: SortDirection | undefined; + priority: number | undefined; +} +``` + +#### `RenderSortIconProps` + +Props for custom sort icon renderers. + +```tsx +interface RenderSortIconProps { + sortDirection: SortDirection | undefined; +} +``` + +#### `RenderSortPriorityProps` + +Props for custom sort priority renderers. + +```tsx +interface RenderSortPriorityProps { + priority: number | undefined; +} +``` + +#### `DataGridHandle` + +Handle type assigned to a grid's `ref` for programmatic grid control. + +```tsx +interface DataGridHandle { + element: HTMLDivElement | null; + scrollToCell: (position: Partial) => void; + selectCell: (position: Position, options?: SelectCellOptions) => void; +} +``` + +**Example:** + +```tsx +import { useRef } from 'react'; +import { DataGrid, DataGridHandle } from 'react-data-grid'; + +function MyGrid() { + const gridRef = useRef(null); + + function scrollToTop() { + gridRef.current?.scrollToCell({ rowIdx: 0 }); + } + + return ; +} +``` + +#### `DefaultColumnOptions` + +Default options applied to all columns. + +```tsx +type DefaultColumnOptions = Pick< + Column, + 'minWidth' | 'maxWidth' | 'resizable' | 'sortable' | 'draggable' +>; +``` + +#### `Direction` + +Grid layout bidirectionality. + +```tsx +type Direction = 'ltr' | 'rtl'; +``` + +#### `Maybe` + +Utility type for optional values. + +```tsx +type Maybe = T | undefined | null; +``` -Please see [CONTRIBUTING](CONTRIBUTING.md) +### Generics -Credits ------------- -This project has been built upon the great work done by [Prometheus Research](https://github.com/prometheusresearch). For the original project, please click [here]( https://github.com/prometheusresearch/react-grid). It is released under [MIT](https://github.com/adazzle/react-data-grid/blob/master/LICENSE) +- `R`, `TRow`: Row type +- `SR`, `TSummaryRow`: Summary row type +- `K`: Row key type diff --git a/addons.js b/addons.js deleted file mode 100644 index c89d3f1996..0000000000 --- a/addons.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("./dist/react-data-grid-with-addons"); diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 28564ca615..0000000000 --- a/appveyor.yml +++ /dev/null @@ -1,63 +0,0 @@ -version: 1.0.{build} -# Fix line endings in Windows. (runs before repo cloning) -init: - - git config --global core.autocrlf input -environment: - COVERALLS_REPO_TOKEN: 9RRu36GLfbnk5Ri6Y6FpoZU10CW6dlIfy - COVERALLS_SERVICE_NAME: appveyor - COVERALLS_GIT_COMMIT: $(APPVEYOR_REPO_COMMIT) - COVERALLS_GIT_BRANCH : $(APPVEYOR_REPO_BRANCH) - COVERALLS_SERVICE_JOB_ID : $(APPVEYOR_BUILD_ID) - COVERALLS_SERVICE_PULL_REQUEST : $(APPVEYOR_PULL_REQUEST_NUMBER) - access_token: - secure: dHfUgllfTEAqpcoz3iQj8TO0DGh8n90Coqf0+IXT0bIRNSIxGTDu991X+FStY613 - npmrc_token: - secure: kGPlcVTOCUp5QVkRPDUGHg== - - -# Install scripts. (runs after repo cloning) -install: - # Decrypt .npmrc.enc file for publishing purposes if not pull request build and not scheduled build - - ps: >- - if($env:APPVEYOR_REPO_BRANCH -ne 'master'){ - ./ci/publish/decrypt-npmrc.ps1 - } - if(!$env:APPVEYOR_SCHEDULED_BUILD -and !$env:appveyor_pull_request_number -and $env:APPVEYOR_REPO_BRANCH -eq 'master') { - ./ci/publish/decrypt-npmrc.ps1 - } - # Get the latest stable version of Node.js or io.js - - ps: Install-Product node 0 - - npm -g install npm@2.11.3 - - set PATH=%APPDATA%\npm;%PATH% - - npm install -g gulp - - npm install - - gulp flow - - gulp dist - -# Post-install test scripts. -test_script: - # Output useful info for debugging. - - node --version - - npm --version - # run tests - - gulp test --release true - - ps: ./test/uploadResults.ps1 - - gulp coveralls - - -# Don't run MS build step -build: off - -cache: - - C:\Users\appveyor\AppData\Roaming\npm\node_modules -> package.json # global npm modules - - C:\Users\appveyor\AppData\Roaming\npm-cache -> package.json # npm cache - - node_modules -> package.json - -on_success: -- ps: >- - if($env:APPVEYOR_REPO_BRANCH -ne 'master'){ - ./ci/publish/publishBranch.ps1 - } - if(!$env:APPVEYOR_SCHEDULED_BUILD -and !$env:appveyor_pull_request_number -and $env:APPVEYOR_REPO_BRANCH -eq 'master') { - ./ci/publish/publishMaster.ps1 - } diff --git a/biome.json b/biome.json new file mode 100644 index 0000000000..23c6797221 --- /dev/null +++ b/biome.json @@ -0,0 +1,385 @@ +{ + "$schema": "./node_modules/@biomejs/biome/configuration_schema.json", + "assist": { "actions": { "source": { "organizeImports": "off" } } }, + "files": { + "includes": [ + "**", + "!.cache/**/*", + "!.cache/**/*", + "!.nitro/**/*", + "!.output/**/*", + "!.tanstack/**/*", + "!coverage/**/*", + "!dist/**/*", + "!lib/**/*", + "!node_modules/**/*", + "!website/routeTree.gen.ts" + ] + }, + "formatter": { + "enabled": false + }, + "json": { + "parser": { + "allowComments": true, + "allowTrailingCommas": true + } + }, + "linter": { + "domains": { + "project": "recommended" + }, + "rules": { + "a11y": { + "noAccessKey": "warn", + "noAriaHiddenOnFocusable": "warn", + "noAriaUnsupportedElements": "warn", + "noAutofocus": "off", + "noDistractingElements": "warn", + "noHeaderScope": "warn", + "noInteractiveElementToNoninteractiveRole": "warn", + "noLabelWithoutControl": "off", + "noNoninteractiveElementToInteractiveRole": "warn", + "noNoninteractiveTabindex": "warn", + "noPositiveTabindex": "warn", + "noRedundantAlt": "warn", + "noRedundantRoles": "warn", + "noStaticElementInteractions": "off", + "noSvgWithoutTitle": "off", + "useAltText": "warn", + "useAnchorContent": "warn", + "useAriaActivedescendantWithTabindex": "warn", + "useAriaPropsForRole": "warn", + "useAriaPropsSupportedByRole": "off", + "useButtonType": "warn", + "useFocusableInteractive": "off", + "useGenericFontNames": "warn", + "useHeadingContent": "warn", + "useHtmlLang": "warn", + "useIframeTitle": "warn", + "useKeyWithClickEvents": "off", + "useKeyWithMouseEvents": "warn", + "useMediaCaption": "off", + "useSemanticElements": "off", + "useValidAnchor": "warn", + "useValidAriaProps": "warn", + "useValidAriaRole": "warn", + "useValidAriaValues": "warn", + "useValidAutocomplete": "warn", + "useValidLang": "warn" + }, + "complexity": { + "noAdjacentSpacesInRegex": "warn", + "noArguments": "warn", + "noBannedTypes": "warn", + "noCommaOperator": "warn", + "noEmptyTypeParameters": "warn", + "noExcessiveCognitiveComplexity": "off", + "noExcessiveLinesPerFunction": "off", + "noExcessiveNestedTestSuites": "off", + "noExtraBooleanCast": "warn", + "noFlatMapIdentity": "warn", + "noForEach": "warn", + "noImplicitCoercions": "warn", + "noStaticOnlyClass": "warn", + "noThisInStatic": "warn", + "noUselessCatch": "warn", + "noUselessConstructor": "warn", + "noUselessContinue": "warn", + "noUselessEmptyExport": "warn", + "noUselessEscapeInRegex": "warn", + "noUselessFragments": "warn", + "noUselessLabel": "warn", + "noUselessLoneBlockStatements": "warn", + "noUselessRename": "warn", + "noUselessStringConcat": "warn", + "noUselessStringRaw": "warn", + "noUselessSwitchCase": "warn", + "noUselessTernary": "warn", + "noUselessThisAlias": "warn", + "noUselessTypeConstraint": "warn", + "noUselessUndefinedInitialization": "warn", + "noVoid": "warn", + "useArrowFunction": "warn", + "useDateNow": "warn", + "useFlatMap": "warn", + "useIndexOf": "warn", + "useLiteralKeys": "warn", + "useNumericLiterals": "warn", + "useOptionalChain": "warn", + "useRegexLiterals": "warn", + "useSimpleNumberKeys": "warn", + "useSimplifiedLogicExpression": "off", + "useWhile": "warn" + }, + "correctness": { + "noChildrenProp": "off", + "noConstAssign": "warn", + "noConstantCondition": "warn", + "noConstantMathMinMaxClamp": "warn", + "noConstructorReturn": "warn", + "noEmptyCharacterClassInRegex": "warn", + "noEmptyPattern": "warn", + "noGlobalDirnameFilename": "warn", + "noGlobalObjectCalls": "warn", + "noInnerDeclarations": "warn", + "noInvalidBuiltinInstantiation": "warn", + "noInvalidConstructorSuper": "warn", + "noInvalidDirectionInLinearGradient": "warn", + "noInvalidGridAreas": "warn", + "noInvalidPositionAtImportRule": "warn", + "noInvalidUseBeforeDeclaration": "warn", + "noNestedComponentDefinitions": "warn", + "noNodejsModules": "warn", + "noNonoctalDecimalEscape": "warn", + "noPrecisionLoss": "warn", + "noPrivateImports": "warn", + "noProcessGlobal": "off", + "noReactPropAssignments": "warn", + "noRenderReturnValue": "warn", + "noRestrictedElements": "off", + "noSelfAssign": "warn", + "noSetterReturn": "warn", + "noStringCaseMismatch": "warn", + "noSwitchDeclarations": "warn", + "noUndeclaredDependencies": "warn", + "noUndeclaredVariables": "off", + "noUnknownFunction": "warn", + "noUnknownMediaFeatureName": "warn", + "noUnknownProperty": "warn", + "noUnknownUnit": "warn", + "noUnmatchableAnbSelector": "warn", + "noUnreachable": "warn", + "noUnreachableSuper": "warn", + "noUnsafeFinally": "warn", + "noUnsafeOptionalChaining": "warn", + "noUnusedFunctionParameters": { + "level": "warn", + "options": { + "ignoreRestSiblings": true + } + }, + "noUnusedImports": "warn", + "noUnusedLabels": "warn", + "noUnusedPrivateClassMembers": "warn", + "noUnusedVariables": { + "level": "warn", + "options": { + "ignoreRestSiblings": true + } + }, + "noVoidElementsWithChildren": "warn", + "noVoidTypeReturn": "warn", + "useExhaustiveDependencies": "off", + "useHookAtTopLevel": "warn", + "useImportExtensions": "off", + "useIsNan": "warn", + "useJsonImportAttributes": "warn", + "useJsxKeyInIterable": "off", + "useParseIntRadix": "warn", + "useSingleJsDocAsterisk": "warn", + "useUniqueElementIds": "off", + "useValidForDirection": "warn", + "useValidTypeof": "warn", + "useYield": "warn" + }, + "performance": { + "noAccumulatingSpread": "warn", + "noAwaitInLoops": "off", + "noBarrelFile": "off", + "noDelete": "warn", + "noDynamicNamespaceImportAccess": "warn", + "noNamespaceImport": "warn", + "noReExportAll": "off", + "useTopLevelRegex": "warn" + }, + "recommended": false, + "security": { + "noBlankTarget": "warn", + "noDangerouslySetInnerHtml": "warn", + "noDangerouslySetInnerHtmlWithChildren": "warn", + "noGlobalEval": "warn" + }, + "style": { + "noDefaultExport": "off", + "noDoneCallback": "warn", + "noEnum": "off", + "noExportedImports": "off", + "noImplicitBoolean": "off", + "noInferrableTypes": "warn", + "noNamespace": "warn", + "noNegationElse": "warn", + "noNonNullAssertion": "off", + "noParameterAssign": "off", + "noParameterProperties": "warn", + "noRestrictedGlobals": "warn", + "noRestrictedImports": { + "level": "warn", + "options": { + "paths": { + "react": { + "importNames": ["default"], + "message": "Use named imports instead." + }, + "react-dom": { + "importNames": ["default"], + "message": "Use named imports instead." + } + } + } + }, + "noShoutyConstants": "warn", + "noSubstr": "off", + "noUnusedTemplateLiteral": "warn", + "noUselessElse": "warn", + "noYodaExpression": "warn", + "useArrayLiterals": "warn", + "useAsConstAssertion": "warn", + "useAtIndex": "off", + "useBlockStatements": "off", + "useCollapsedElseIf": "warn", + "useCollapsedIf": "warn", + "useComponentExportOnlyModules": "off", + "useConsistentArrayType": "warn", + "useConsistentBuiltinInstantiation": "warn", + "useConsistentObjectDefinitions": "warn", + "useConst": "warn", + "useDefaultParameterLast": "off", + "useDefaultSwitchClause": "warn", + "useEnumInitializers": "warn", + "useExplicitLengthCheck": "off", + "useExponentiationOperator": "warn", + "useExportType": "warn", + "useFilenamingConvention": "off", + "useForOf": "off", + "useFragmentSyntax": "warn", + "useImportType": "warn", + "useLiteralEnumMembers": "warn", + "useNamingConvention": "off", + "useNodeAssertStrict": "warn", + "useNodejsImportProtocol": "warn", + "useNumberNamespace": "warn", + "useNumericSeparators": "off", + "useObjectSpread": "warn", + "useSelfClosingElements": "warn", + "useShorthandAssign": "warn", + "useShorthandFunctionType": "warn", + "useSingleVarDeclarator": "warn", + "useSymbolDescription": "warn", + "useTemplate": "warn", + "useThrowNewError": "warn", + "useThrowOnlyError": "warn", + "useTrimStartEnd": "warn" + }, + "suspicious": { + "noApproximativeNumericConstant": "warn", + "noArrayIndexKey": "off", + "noAssignInExpressions": "warn", + "noAsyncPromiseExecutor": "warn", + "noCatchAssign": "warn", + "noClassAssign": "warn", + "noCommentText": "warn", + "noCompareNegZero": "warn", + "noConfusingLabels": "warn", + "noConfusingVoidType": "warn", + "noConsole": "warn", + "noConstantBinaryExpressions": "warn", + "noConstEnum": "warn", + "noControlCharactersInRegex": "warn", + "noDebugger": "warn", + "noDoubleEquals": "warn", + "noDuplicateAtImportRules": "warn", + "noDuplicateCase": "warn", + "noDuplicateClassMembers": "warn", + "noDuplicateElseIf": "warn", + "noDuplicateFontNames": "warn", + "noDuplicateJsxProps": "warn", + "noDuplicateObjectKeys": "warn", + "noDuplicateParameters": "warn", + "noDuplicateSelectorsKeyframeBlock": "warn", + "noDuplicateTestHooks": "warn", + "noEmptyBlock": "warn", + "noEmptyBlockStatements": "off", + "noEmptyInterface": "warn", + "noEvolvingTypes": "off", + "noExplicitAny": "off", + "noExportsInTest": "warn", + "noExtraNonNullAssertion": "warn", + "noFallthroughSwitchClause": "warn", + "noFocusedTests": "warn", + "noFunctionAssign": "warn", + "noGlobalAssign": "warn", + "noGlobalIsFinite": "warn", + "noGlobalIsNan": "warn", + "noImplicitAnyLet": "off", + "noImportAssign": "warn", + "noImportantInKeyframe": "warn", + "noLabelVar": "warn", + "noMisleadingCharacterClass": "warn", + "noMisleadingInstantiator": "warn", + "noMisplacedAssertion": "off", + "noMisrefactoredShorthandAssign": "warn", + "noOctalEscape": "warn", + "noPrototypeBuiltins": "warn", + "noReactSpecificProps": "off", + "noRedeclare": "warn", + "noRedundantUseStrict": "warn", + "noSelfCompare": "warn", + "noShadowRestrictedNames": "warn", + "noShorthandPropertyOverrides": "warn", + "noSkippedTests": "warn", + "noSparseArray": "warn", + "noSuspiciousSemicolonInJsx": "warn", + "noTemplateCurlyInString": "warn", + "noThenProperty": "warn", + "noTsIgnore": "warn", + "noUnsafeDeclarationMerging": "warn", + "noUnsafeNegation": "warn", + "noUselessEscapeInString": "warn", + "noUselessRegexBackrefs": "warn", + "noVar": "warn", + "noWith": "warn", + "useAwait": "warn", + "useDefaultSwitchClauseLast": "warn", + "useErrorMessage": "warn", + "useGetterReturn": "warn", + "useIsArray": "warn", + "useNamespaceKeyword": "warn", + "useNumberToFixedDigitsArgument": "warn" + } + } + }, + "overrides": [ + { + "includes": ["**/*.test.*"], + "linter": { + "rules": { + "performance": { + "useTopLevelRegex": "off" + } + } + } + }, + { + "includes": ["**/*.js", "**/rolldown.config.ts"], + "linter": { + "rules": { + "correctness": { + "noNodejsModules": "off" + }, + "suspicious": { + "noConsole": "off" + } + } + } + }, + { + "assist": { + "actions": { + "source": { "useSortedKeys": "on" } + } + }, + "includes": ["./biome.json"] + } + ] +} diff --git a/bower.json b/bower.json deleted file mode 100644 index 2a0e63270b..0000000000 --- a/bower.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "name": "react-data-grid", - "main": "index.js", - "version": "0.12.4", - "homepage": "https://github.com/adazzle/react-data-grid", - "authors": [ - "malonecj " - ], - "description": "Excel-like grid component built with React, with editors, keyboard navigation, copy & paste, and the like", - "license": "MIT", - "ignore": [ - "gulp", - "node_modules", - "bower_components", - "test", - "tests", - "src", - "coveralls.yml", - "gulpfile.js", - "webpack.config.js", - ".npmignore", - ".gitignore", - ".eslintrc", - "examples", - "config" - ] -} diff --git a/ci/publish/decrypt-npmrc.ps1 b/ci/publish/decrypt-npmrc.ps1 deleted file mode 100644 index 4658ec1f9a..0000000000 --- a/ci/publish/decrypt-npmrc.ps1 +++ /dev/null @@ -1,3 +0,0 @@ -Write-Host "Decrypting .npmrc.enc file with secure-file" -nuget install secure-file -ExcludeVersion -secure-file\tools\secure-file -decrypt .npmrc.enc -secret $($env:npmrc_token) diff --git a/ci/publish/getCurrentVersion.js b/ci/publish/getCurrentVersion.js deleted file mode 100644 index 5c5fcff70b..0000000000 --- a/ci/publish/getCurrentVersion.js +++ /dev/null @@ -1,4 +0,0 @@ -var semver = require('semver'); -fs = require('fs') -json = JSON.parse(fs.readFileSync('./package.json', 'utf8')) -process.stdout.write(json.version); diff --git a/ci/publish/getNextVersion.js b/ci/publish/getNextVersion.js deleted file mode 100644 index ae8b9584b9..0000000000 --- a/ci/publish/getNextVersion.js +++ /dev/null @@ -1,24 +0,0 @@ -var semver = require('semver'); -fs = require('fs') -json = JSON.parse(fs.readFileSync('./package.json', 'utf8')) -var execSync = require('child_process').execSync, - child; - -/** - * Generates a new pre-release version based on current version and git branch name - * - * @param version - The currrent version of the package - * @param branchName - The name of the current git branch - * @returns nextVersion - The new version of the branch in the format major.minor.patch-branchName.x - */ -function getNextVersion(version, branchName, buildNumber){ - var nextVersion = semver.major(version) + "." + semver.minor(version) + "." + semver.patch(version) + "-" + branchName + buildNumber; - if(semver.valid(nextVersion)){ - return nextVersion; - } else{ - console.error(next + " is not a valid npm version"); - } -} - -var nextVersion = getNextVersion(json.version, process.env.APPVEYOR_REPO_BRANCH, process.env.APPVEYOR_BUILD_NUMBER); -process.stdout.write(nextVersion); diff --git a/ci/publish/publishBranch.ps1 b/ci/publish/publishBranch.ps1 deleted file mode 100644 index 7a18445f70..0000000000 --- a/ci/publish/publishBranch.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -$nextVersion = node ./ci/publish/getNextVersion -git config --global credential.helper store -git config --global push.default simple -Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:access_token)%3Ax-oauth-basic@github.com`n/" -git config --global user.name $env:APPVEYOR_REPO_COMMIT_AUTHOR -git config --global user.email $env:APPVEYOR_REPO_COMMIT_AUTHOR_EMAIL -git checkout $env:APPVEYOR_REPO_BRANCH -npm version $nextVersion --message "Version Bump : $($nextVersion) [ci skip]" -Write-Host "Publishing $($nextVersion) to npm" -if($?) -{ - npm publish . --tag $env:APPVEYOR_REPO_BRANCH -} - -exit $lastexitcode diff --git a/ci/publish/publishMaster.ps1 b/ci/publish/publishMaster.ps1 deleted file mode 100644 index 54dfc65b74..0000000000 --- a/ci/publish/publishMaster.ps1 +++ /dev/null @@ -1,25 +0,0 @@ -Write-Host "Merging to master. Attempting to bump version" -git config --global credential.helper store -git config --global push.default simple -Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:access_token)%3Ax-oauth-basic@github.com`n/" -git config --global user.name $env:APPVEYOR_REPO_COMMIT_AUTHOR -git config --global user.email $env:APPVEYOR_REPO_COMMIT_AUTHOR_EMAIL -git checkout master -npm version patch --message "Version Bump [ci skip]" -$currentVersion = node ./ci/publish/getCurrentVersion -git commit --amend -m "Version Bump to $($currentVersion) [ci skip]" -git fetch -git pull --rebase -git push -git push --tags -Write-Host "Publishing $($currentVersion) to npm" -if($?) -{ - npm publish - if($?){ - Write-Host "regenerating public site and examples" - gulp docs - } -} - -exit $lastexitcode diff --git a/config/karma.js b/config/karma.js deleted file mode 100644 index 6e531a3912..0000000000 --- a/config/karma.js +++ /dev/null @@ -1,184 +0,0 @@ -/* -* In local config, only run tests using phantom js. No code coverage reports applied -*/ -var webpack = require('webpack'); -var webpackConfig = require('./webpack.js'); -var RewirePlugin = require("rewire-webpack"); -var path = require('path'); -var argv = require('minimist')(process.argv.slice(2)); -var RELEASE = !!argv.release; -var DEBUG = !!argv.debug; -var BROWSERS = argv.browsers; - - -module.exports = function (config) { - - function getPostLoaders(){ - var postLoaders = []; - if(RELEASE === true){ - return [ { - test: /\.(js|jsx)$/, - exclude: /node_modules/, - loader: 'istanbul-instrumenter' - } ] - } - return postLoaders; - }; - - function getReporters(){ - if(RELEASE === true){ - return ['junit', 'progress', 'coverage'] - }else{ - return ['junit', 'progress'] - } - }; - - function getBrowsers(){ - var browsers = ['PhantomJS']; - if(BROWSERS) { - return BROWSERS.split(','); - } - if(RELEASE){ - browsers = ['Chrome','Firefox','IE'] - }else if(DEBUG){ - browsers = ['Chrome']; - } - return browsers; - }; - - function getFiles() { - var files; - if(RELEASE === true || DEBUG === true) { - files = [ - 'node_modules/es5-shim/es5-shim.js', - 'node_modules/es5-shim/es5-sham.js', - 'test/FullTests.jsx' - ] - } else { - files = [ - 'node_modules/es5-shim/es5-shim.js', - 'node_modules/es5-shim/es5-sham.js', - 'test/unitTests.jsx' - ] - } - return files; - } - - function getPreprocessors() { - var preprocessors; - if(RELEASE === true || DEBUG === true) { - preprocessors = { - 'test/FullTests.jsx': ['webpack'] - } - } else { - preprocessors = {'test/unitTests.jsx': ['webpack']} - } - return preprocessors; - } - - function lookupPhantomJS() { - try { - return require('phantomjs').path; - } catch(e){ - return; - } - } - - config.set({ - - basePath: path.join(__dirname, '../'), - - files: getFiles(), - - preprocessors: getPreprocessors(), - - webpack: { - module: { - loaders: webpackConfig.module.loaders, - postLoaders : getPostLoaders() - }, - resolve: { - extensions: ['', '.webpack.js', '.web.js', '.js', '.jsx'] - }, - plugins: [ - new RewirePlugin() - ] - }, - - webpackServer: { - stats: { - colors: true - } - }, - - webpackMiddleware: { - // webpack-dev-middleware configuration - // i. e. - noInfo: true - }, - - browserNoActivityTimeout: 1000000, - - // coverage reporter generates the coverage - reporters: ['junit', 'progress', 'coverage'], - - - coverageReporter: { - // specify a common output directory - dir: 'test/coverage', - reporters: [ - // reporters not supporting the `file` property - { type: 'html', subdir: 'report-html' }, - { type: 'lcov', subdir: 'report-lcov' } - ] - }, - - // the default configuration - junitReporter: { - outputFile: 'test/coverage/test-results.xml', - outputDir: 'test/coverage', - suite: '' - }, - - autoWatch: false, - - frameworks: [ - 'jasmine', - 'jasmine-matchers' - ], - - browsers: getBrowsers(), - - plugins: [ - 'karma-chrome-launcher', - 'karma-firefox-launcher', - 'karma-phantomjs-launcher-nonet', - 'karma-ie-launcher', - 'karma-jasmine', - 'karma-jasmine-matchers', - 'karma-webpack', - 'karma-junit-reporter', - 'karma-coverage' - ], - - customLaunchers: { - IE9: { - base: 'IE', - 'x-ua-compatible': 'IE=EmulateIE9' - }, - IE8: { - base: 'IE', - 'x-ua-compatible': 'IE=EmulateIE8' - } - }, - - phantomjsLauncher: { - // configure PhantomJS executable for each platform - cmd: { - linux: lookupPhantomJS(), - darwin: lookupPhantomJS(), - win32: path.join(__dirname, '../test/browser/phantomjs.exe') - } - } - }); -}; diff --git a/config/webpack.js b/config/webpack.js deleted file mode 100644 index 4bb6cb9baf..0000000000 --- a/config/webpack.js +++ /dev/null @@ -1,53 +0,0 @@ -var path = require("path"); -var webpack = require('webpack'); -var release = false; -var path = require("path"); -var argv = require('minimist')(process.argv.slice(2)); -var RELEASE = argv.release; - - -var config = { - entry: { - 'react-data-grid' : './src/index', - 'react-data-grid-with-addons' : './src/addons/index' - }, - output: { - path: path.join(__dirname, "../dist"), - filename: "[name].js", - library: ["ReactDataGrid"], - libraryTarget: "umd" - }, - externals: { - "react": { - root : 'React', - commonjs : 'react', - commonjs2 : 'react', - amd : 'react' - }, - "react/addons": { - root : 'React', - commonjs : 'react', - commonjs2 : 'react', - amd : 'react' - }, - "moment" : "moment" - }, - module: { - loaders: [ - { - test: /\.js$/, - exclude: /node_modules/, - loader: 'babel-loader?optional[]=runtime' - } - ] - }, - postLoaders: [ - { - test: /\.js$/, - exclude: /node_modules|testData/, - loader: 'jshint' - }] -} - - -module.exports = config; diff --git a/coveralls.yml b/coveralls.yml deleted file mode 100644 index 0ea7887ebc..0000000000 --- a/coveralls.yml +++ /dev/null @@ -1 +0,0 @@ -repo_token: 9RRu36GLfbnk5Ri6Y6FpoZU10CW6dlIfy diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 0000000000..6edf43f002 --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,781 @@ +import reactX from '@eslint-react/eslint-plugin'; +import markdown from '@eslint/markdown'; +import typescriptEslint from '@typescript-eslint/eslint-plugin'; +import tsParser from '@typescript-eslint/parser'; +import vitest from '@vitest/eslint-plugin'; +import jestDom from 'eslint-plugin-jest-dom'; +import react from 'eslint-plugin-react'; +import reactHooks from 'eslint-plugin-react-hooks'; +import sonarjs from 'eslint-plugin-sonarjs'; +import testingLibrary from 'eslint-plugin-testing-library'; +import { defineConfig, globalIgnores } from 'eslint/config'; + +export default defineConfig([ + globalIgnores(['.cache', '.nitro', '.output', '.tanstack', 'coverage', 'dist', 'lib']), + + { + linterOptions: { + reportUnusedInlineConfigs: 'warn' + } + }, + + { + name: 'common', + files: ['**/*.{js,ts,tsx}'], + + plugins: { + react, + 'react-hooks': reactHooks, + 'react-x': reactX, + sonarjs, + '@typescript-eslint': typescriptEslint + }, + + languageOptions: { + parser: tsParser, + + parserOptions: { + ecmaVersion: 'latest', + jsxPragma: null, + projectService: true, + warnOnUnsupportedTypeScriptVersion: false + } + }, + + settings: { + react: { + version: 'detect' + } + }, + + rules: { + // Possible Problems + // https://eslint.org/docs/latest/rules/#possible-problems + 'array-callback-return': [1, { checkForEach: true }], + 'constructor-super': 0, // covered by TS + 'for-direction': 1, + 'getter-return': 1, + 'no-async-promise-executor': 1, + 'no-await-in-loop': 0, + 'no-class-assign': 0, + 'no-compare-neg-zero': 1, + 'no-cond-assign': 1, + 'no-const-assign': 0, + 'no-constant-binary-expression': 1, + 'no-constant-condition': 1, + 'no-constructor-return': 1, + 'no-control-regex': 1, + 'no-debugger': 1, + 'no-dupe-args': 1, + 'no-dupe-class-members': 0, + 'no-dupe-else-if': 1, + 'no-dupe-keys': 1, + 'no-duplicate-case': 1, + 'no-duplicate-imports': 0, + 'no-empty-character-class': 1, + 'no-empty-pattern': 1, + 'no-ex-assign': 1, + 'no-fallthrough': [1, { reportUnusedFallthroughComment: true }], + 'no-func-assign': 1, + 'no-import-assign': 1, + 'no-inner-declarations': 0, + 'no-invalid-regexp': 1, + 'no-irregular-whitespace': 1, + 'no-loss-of-precision': 1, + 'no-misleading-character-class': 1, + 'no-new-native-nonconstructor': 1, + 'no-obj-calls': 1, + 'no-promise-executor-return': 1, + 'no-prototype-builtins': 1, + 'no-self-assign': [1, { props: true }], + 'no-self-compare': 1, + 'no-setter-return': 1, + 'no-sparse-arrays': 1, + 'no-template-curly-in-string': 1, + 'no-this-before-super': 0, + 'no-unassigned-vars': 1, + 'no-undef': 0, + 'no-unexpected-multiline': 0, + 'no-unmodified-loop-condition': 1, + 'no-unreachable': 1, + 'no-unreachable-loop': 1, + 'no-unsafe-finally': 1, + 'no-unsafe-negation': [1, { enforceForOrderingRelations: true }], + 'no-unsafe-optional-chaining': [1, { disallowArithmeticOperators: true }], + 'no-unused-private-class-members': 0, // replaced by @typescript-eslint/no-unused-private-class-members + 'no-unused-vars': 0, // replaced by @typescript-eslint/no-unused-vars + 'no-use-before-define': 0, + 'no-useless-backreference': 1, + 'require-atomic-updates': 1, + 'use-isnan': [1, { enforceForIndexOf: true }], + 'valid-typeof': [1, { requireStringLiterals: true }], + + // Suggestions + // https://eslint.org/docs/latest/rules/#suggestions + 'accessor-pairs': 1, + 'arrow-body-style': 0, + 'block-scoped-var': 1, + camelcase: 0, + 'capitalized-comments': 0, + 'class-methods-use-this': 1, + complexity: 0, + 'consistent-return': 0, + 'consistent-this': 0, + curly: 0, + 'default-case': 1, + 'default-case-last': 1, + 'default-param-last': 0, + 'dot-notation': 0, // replaced by @typescript-eslint/dot-notation + eqeqeq: [1, 'always', { null: 'ignore' }], + 'func-name-matching': 0, + 'func-names': 0, + 'func-style': 0, + 'grouped-accessor-pairs': [1, 'getBeforeSet'], + 'guard-for-in': 0, + 'id-denylist': 0, + 'id-length': 0, + 'id-match': 0, + 'init-declarations': 0, + 'logical-assignment-operators': [1, 'always', { enforceForIfStatements: true }], + 'max-classes-per-file': 0, + 'max-depth': 0, + 'max-lines': 0, + 'max-lines-per-function': 0, + 'max-nested-callbacks': 0, + 'max-params': 0, + 'max-statements': 0, + 'multiline-comment-style': 0, + 'new-cap': 0, + 'no-alert': 0, + 'no-array-constructor': 1, + 'no-bitwise': 0, + 'no-caller': 1, + 'no-case-declarations': 1, + 'no-console': 1, + 'no-continue': 0, + 'no-delete-var': 1, + 'no-div-regex': 0, + 'no-else-return': [1, { allowElseIf: false }], + 'no-empty': [1, { allowEmptyCatch: true }], + 'no-empty-function': 0, + 'no-empty-static-block': 1, + 'no-eq-null': 0, + 'no-eval': 1, + 'no-extend-native': 1, + 'no-extra-bind': 1, + 'no-extra-boolean-cast': [1, { enforceForLogicalOperands: true }], + 'no-extra-label': 1, + 'no-global-assign': 1, + 'no-implicit-coercion': 0, + 'no-implicit-globals': 0, + 'no-implied-eval': 0, // replaced by @typescript-eslint/no-implied-eval + 'no-inline-comments': 0, + 'no-invalid-this': 0, + 'no-iterator': 1, + 'no-label-var': 1, + 'no-labels': 1, + 'no-lone-blocks': 1, + 'no-lonely-if': 1, + 'no-loop-func': 0, + 'no-magic-numbers': 0, + 'no-multi-assign': 0, + 'no-multi-str': 1, + 'no-negated-condition': 0, + 'no-nested-ternary': 0, + 'no-new': 1, + 'no-new-func': 1, + 'no-new-wrappers': 1, + 'no-nonoctal-decimal-escape': 1, + 'no-object-constructor': 1, + 'no-octal': 1, + 'no-octal-escape': 1, + 'no-param-reassign': 0, + 'no-plusplus': 0, + 'no-proto': 1, + 'no-redeclare': 0, // replaced by @typescript-eslint/no-redeclare + 'no-regex-spaces': 1, + 'no-restricted-exports': 0, + 'no-restricted-globals': [ + 1, + { + name: 'Omit', + message: 'Use Omit from types instead.' + } + ], + 'no-restricted-imports': 0, // replaced by @typescript-eslint/no-restricted-imports + 'no-restricted-properties': 0, + 'no-restricted-syntax': 0, + 'no-return-assign': 0, + 'no-return-await': 0, // replaced by @typescript-eslint/return-await + 'no-script-url': 1, + 'no-sequences': [1, { allowInParentheses: false }], + 'no-shadow': 0, + 'no-shadow-restricted-names': 1, + 'no-ternary': 0, + 'no-throw-literal': 0, // replaced by @typescript-eslint/only-throw-error + 'no-undef-init': 1, + 'no-undefined': 0, + 'no-underscore-dangle': 0, + 'no-unneeded-ternary': [1, { defaultAssignment: false }], + 'no-unused-expressions': [1, { allowTaggedTemplates: true, enforceForJSX: true }], + 'no-unused-labels': 1, + 'no-useless-call': 1, + 'no-useless-catch': 1, + 'no-useless-computed-key': 1, + 'no-useless-concat': 1, + 'no-useless-constructor': 1, + 'no-useless-escape': 1, + 'no-useless-rename': 1, + 'no-useless-return': 1, + 'no-var': 1, + 'no-void': 1, + 'no-warning-comments': 0, + 'no-with': 1, + 'object-shorthand': [1, 'always', { avoidExplicitReturnArrows: true }], + 'one-var': [1, 'never'], + 'operator-assignment': 1, + 'prefer-arrow-callback': [1, { allowNamedFunctions: true }], + 'prefer-const': [1, { destructuring: 'all' }], + 'prefer-destructuring': 0, // replaced by @typescript-eslint/prefer-destructuring + 'prefer-exponentiation-operator': 1, + 'prefer-named-capture-group': 0, + 'prefer-numeric-literals': 1, + 'prefer-object-has-own': 1, + 'prefer-object-spread': 1, + 'prefer-promise-reject-errors': 0, // replaced by @typescript-eslint/prefer-promise-reject-errors + 'prefer-regex-literals': [1, { disallowRedundantWrapping: true }], + 'prefer-rest-params': 1, + 'prefer-spread': 1, + 'prefer-template': 1, + 'preserve-caught-error': 1, + radix: 1, + 'require-await': 0, // replaced by @typescript-eslint/require-await + 'require-unicode-regexp': 0, + 'require-yield': 1, + 'sort-imports': 0, + 'sort-keys': 0, + 'sort-vars': 0, + strict: 1, + 'symbol-description': 1, + 'vars-on-top': 0, + yoda: 0, + + // Layout & Formatting + // https://eslint.org/docs/latest/rules/#layout--formatting + 'unicode-bom': 1, + + // React rules + // https://github.com/jsx-eslint/eslint-plugin-react#list-of-supported-rules + 'react/boolean-prop-naming': 0, + 'react/button-has-type': 0, + 'react/checked-requires-onchange-or-readonly': 1, + 'react/default-props-match-prop-types': 0, + 'react/destructuring-assignment': 0, + 'react/display-name': 0, + 'react/forbid-component-props': 0, + 'react/forbid-dom-props': 0, + 'react/forbid-elements': 0, + 'react/forbid-foreign-prop-types': 0, + 'react/forbid-prop-types': 0, + 'react/forward-ref-uses-ref': 1, + 'react/function-component-definition': [ + 1, + { + namedComponents: 'function-declaration', + unnamedComponents: 'function-expression' + } + ], + 'react/hook-use-state': 0, + 'react/iframe-missing-sandbox': 1, + 'react/jsx-boolean-value': 1, + 'react/jsx-child-element-spacing': 0, + 'react/jsx-closing-bracket-location': 0, + 'react/jsx-closing-tag-location': 0, + 'react/jsx-curly-brace-presence': 1, + 'react/jsx-curly-newline': 0, + 'react/jsx-curly-spacing': 0, + 'react/jsx-equals-spacing': 0, + 'react/jsx-filename-extension': [1, { extensions: ['.tsx'] }], + 'react/jsx-first-prop-new-line': 0, + 'react/jsx-fragments': 1, + 'react/jsx-handler-names': 0, + 'react/jsx-indent': 0, + 'react/jsx-indent-props': 0, + 'react/jsx-key': [ + 1, + { + checkFragmentShorthand: true, + checkKeyMustBeforeSpread: true, + warnOnDuplicates: true + } + ], + 'react/jsx-max-depth': 0, + 'react/jsx-max-props-per-line': 0, + 'react/jsx-newline': 0, + 'react/jsx-no-bind': 0, + 'react/jsx-no-comment-textnodes': 1, + 'react/jsx-no-constructed-context-values': 1, + 'react/jsx-no-duplicate-props': 0, + 'react/jsx-no-leaked-render': 0, + 'react/jsx-no-literals': 0, + 'react/jsx-no-script-url': 1, + 'react/jsx-no-target-blank': 1, + 'react/jsx-no-undef': 0, + 'react/jsx-no-useless-fragment': 1, + 'react/jsx-one-expression-per-line': 0, + 'react/jsx-pascal-case': 1, + 'react/jsx-props-no-multi-spaces': 0, + 'react/jsx-props-no-spread-multi': 1, + 'react/jsx-props-no-spreading': 0, + 'react/jsx-sort-props': 0, + 'react/jsx-tag-spacing': 0, + 'react/jsx-uses-react': 0, + 'react/jsx-uses-vars': 1, + 'react/jsx-wrap-multilines': 0, + 'react/no-access-state-in-setstate': 1, + 'react/no-adjacent-inline-elements': 0, + 'react/no-array-index-key': 0, + 'react/no-arrow-function-lifecycle': 0, + 'react/no-children-prop': 0, + 'react/no-danger': 1, + 'react/no-danger-with-children': 1, + 'react/no-deprecated': 1, + 'react/no-did-mount-set-state': 1, + 'react/no-did-update-set-state': 1, + 'react/no-direct-mutation-state': 1, + 'react/no-find-dom-node': 0, + 'react/no-invalid-html-attribute': 1, + 'react/no-is-mounted': 1, + 'react/no-multi-comp': 0, + 'react/no-namespace': 0, + 'react/no-object-type-as-default-prop': 1, + 'react/no-redundant-should-component-update': 1, + 'react/no-render-return-value': 0, + 'react/no-set-state': 0, + 'react/no-string-refs': [1, { noTemplateLiterals: true }], + 'react/no-this-in-sfc': 0, + 'react/no-typos': 1, + 'react/no-unescaped-entities': 0, + 'react/no-unknown-property': 0, + 'react/no-unsafe': 1, + 'react/no-unstable-nested-components': [1, { allowAsProps: true }], + 'react/no-unused-class-component-methods': 0, + 'react/no-unused-prop-types': 0, + 'react/no-unused-state': 0, + 'react/no-will-update-set-state': 1, + 'react/prefer-es6-class': 1, + 'react/prefer-exact-props': 0, + 'react/prefer-read-only-props': 0, + 'react/prefer-stateless-function': 0, + 'react/prop-types': 0, + 'react/react-in-jsx-scope': 0, + 'react/require-default-props': 0, + 'react/require-optimization': 0, + 'react/require-render-return': 1, + 'react/self-closing-comp': 1, + 'react/sort-comp': 0, + 'react/sort-default-props': 0, + 'react/sort-prop-types': 0, + 'react/state-in-constructor': 0, + 'react/static-property-placement': 1, + 'react/style-prop-object': 0, + 'react/void-dom-elements-no-children': 1, + + // React Hooks + // https://www.npmjs.com/package/eslint-plugin-react-hooks + 'react-hooks/rules-of-hooks': 1, + 'react-hooks/exhaustive-deps': 1, + 'react-hooks/component-hook-factories': 1, + 'react-hooks/config': 1, + 'react-hooks/error-boundaries': 1, + 'react-hooks/gating': 1, + 'react-hooks/globals': 1, + 'react-hooks/immutability': 0, + 'react-hooks/incompatible-library': 1, + 'react-hooks/preserve-manual-memoization': 1, + 'react-hooks/purity': 1, + 'react-hooks/refs': 1, + 'react-hooks/set-state-in-effect': 1, + 'react-hooks/set-state-in-render': 1, + 'react-hooks/static-components': 1, + 'react-hooks/unsupported-syntax': 1, + 'react-hooks/use-memo': 1, + + // React Hooks Extra + // https://eslint-react.xyz/ + 'react-x/no-unnecessary-use-callback': 1, + 'react-x/no-unnecessary-use-memo': 1, + 'react-x/no-unnecessary-use-prefix': 1, + 'react-x/prefer-use-state-lazy-initialization': 1, + + // SonarJS rules + // https://github.com/SonarSource/eslint-plugin-sonarjs#rules + 'sonarjs/no-all-duplicated-branches': 1, + 'sonarjs/no-element-overwrite': 1, + 'sonarjs/no-empty-collection': 1, + 'sonarjs/no-extra-arguments': 0, + 'sonarjs/no-identical-conditions': 1, + 'sonarjs/no-identical-expressions': 1, + 'sonarjs/no-ignored-return': 1, + 'sonarjs/no-use-of-empty-return-value': 1, + 'sonarjs/non-existent-operator': 1, + 'sonarjs/cognitive-complexity': 0, + 'sonarjs/elseif-without-else': 0, + 'sonarjs/max-switch-cases': 0, + 'sonarjs/no-collapsible-if': 1, + 'sonarjs/no-collection-size-mischeck': 1, + 'sonarjs/no-duplicate-string': 0, + 'sonarjs/no-duplicated-branches': 1, + 'sonarjs/no-gratuitous-expressions': 1, + 'sonarjs/no-identical-functions': 1, + 'sonarjs/no-inverted-boolean-check': 1, + 'sonarjs/no-nested-switch': 1, + 'sonarjs/no-nested-template-literals': 1, + 'sonarjs/no-redundant-boolean': 1, + 'sonarjs/no-redundant-jump': 1, + 'sonarjs/no-same-line-conditional': 1, + 'sonarjs/no-small-switch': 1, + 'sonarjs/no-unused-collection': 1, + 'sonarjs/no-useless-catch': 1, + 'sonarjs/prefer-immediate-return': 1, + 'sonarjs/prefer-object-literal': 1, + 'sonarjs/prefer-single-boolean-return': 1, + 'sonarjs/prefer-while': 1, + + // @typescript-eslint/eslint-plugin rules + // https://typescript-eslint.io/rules/#supported-rules + '@typescript-eslint/adjacent-overload-signatures': 1, + '@typescript-eslint/array-type': 0, + '@typescript-eslint/await-thenable': 1, + '@typescript-eslint/ban-ts-comment': [1, { 'ts-expect-error': false }], + '@typescript-eslint/ban-tslint-comment': 0, + '@typescript-eslint/class-literal-property-style': 0, + '@typescript-eslint/class-methods-use-this': 0, + '@typescript-eslint/consistent-generic-constructors': 1, + '@typescript-eslint/consistent-indexed-object-style': 1, + '@typescript-eslint/consistent-return': 0, + '@typescript-eslint/consistent-type-assertions': [ + 1, + { assertionStyle: 'as', objectLiteralTypeAssertions: 'never' } + ], + '@typescript-eslint/consistent-type-definitions': 1, + '@typescript-eslint/consistent-type-exports': 0, + '@typescript-eslint/consistent-type-imports': [1, { fixStyle: 'inline-type-imports' }], + '@typescript-eslint/explicit-function-return-type': 0, + '@typescript-eslint/explicit-member-accessibility': 0, + '@typescript-eslint/explicit-module-boundary-types': 0, + '@typescript-eslint/member-ordering': 0, + '@typescript-eslint/method-signature-style': 1, + '@typescript-eslint/naming-convention': 0, + '@typescript-eslint/no-array-delete': 1, + '@typescript-eslint/no-base-to-string': 0, + '@typescript-eslint/no-confusing-non-null-assertion': 0, + '@typescript-eslint/no-confusing-void-expression': [1, { ignoreArrowShorthand: true }], + '@typescript-eslint/no-deprecated': 1, + '@typescript-eslint/no-duplicate-enum-values': 1, + '@typescript-eslint/no-duplicate-type-constituents': 1, + '@typescript-eslint/no-dynamic-delete': 0, + '@typescript-eslint/no-empty-object-type': 1, + '@typescript-eslint/no-explicit-any': [1, { fixToUnknown: true }], + '@typescript-eslint/no-extra-non-null-assertion': 1, + '@typescript-eslint/no-extraneous-class': 1, + '@typescript-eslint/no-floating-promises': 0, + '@typescript-eslint/no-for-in-array': 1, + '@typescript-eslint/no-import-type-side-effects': 0, + '@typescript-eslint/no-inferrable-types': 1, + '@typescript-eslint/no-invalid-void-type': 1, + '@typescript-eslint/no-meaningless-void-operator': 0, + '@typescript-eslint/no-misused-new': 1, + '@typescript-eslint/no-misused-promises': 0, + '@typescript-eslint/no-misused-spread': 1, + '@typescript-eslint/no-mixed-enums': 1, + '@typescript-eslint/no-namespace': 1, + '@typescript-eslint/no-non-null-asserted-nullish-coalescing': 1, + '@typescript-eslint/no-non-null-asserted-optional-chain': 1, + '@typescript-eslint/no-non-null-assertion': 0, + '@typescript-eslint/no-redundant-type-constituents': 1, + '@typescript-eslint/no-require-imports': 1, + '@typescript-eslint/no-restricted-types': 0, + '@typescript-eslint/no-this-alias': 0, + '@typescript-eslint/no-type-alias': 0, + '@typescript-eslint/no-unnecessary-boolean-literal-compare': 1, + '@typescript-eslint/no-unnecessary-condition': [1, { checkTypePredicates: true }], + '@typescript-eslint/no-unnecessary-parameter-property-assignment': 1, + '@typescript-eslint/no-unnecessary-qualifier': 0, + '@typescript-eslint/no-unnecessary-template-expression': 1, + '@typescript-eslint/no-unnecessary-type-arguments': 1, + '@typescript-eslint/no-unnecessary-type-assertion': 1, + '@typescript-eslint/no-unnecessary-type-constraint': 1, + '@typescript-eslint/no-unnecessary-type-conversion': 1, + '@typescript-eslint/no-unnecessary-type-parameters': 1, + '@typescript-eslint/no-unsafe-argument': 0, + '@typescript-eslint/no-unsafe-assignment': 0, + '@typescript-eslint/no-unsafe-call': 0, + '@typescript-eslint/no-unsafe-declaration-merging': 1, + '@typescript-eslint/no-unsafe-enum-comparison': 1, + '@typescript-eslint/no-unsafe-function-type': 1, + '@typescript-eslint/no-unsafe-member-access': 0, + '@typescript-eslint/no-unsafe-return': 1, + '@typescript-eslint/no-unsafe-type-assertion': 0, + '@typescript-eslint/no-unsafe-unary-minus': 1, + '@typescript-eslint/no-useless-empty-export': 1, + '@typescript-eslint/no-var-requires': 0, + '@typescript-eslint/no-wrapper-object-types': 1, + '@typescript-eslint/non-nullable-type-assertion-style': 1, + '@typescript-eslint/parameter-properties': 1, + '@typescript-eslint/prefer-as-const': 1, + '@typescript-eslint/prefer-destructuring': [1, { array: false }], + '@typescript-eslint/prefer-enum-initializers': 0, + '@typescript-eslint/prefer-find': 1, + '@typescript-eslint/prefer-for-of': 1, + '@typescript-eslint/prefer-function-type': 1, + '@typescript-eslint/prefer-includes': 1, + '@typescript-eslint/prefer-literal-enum-member': 1, + '@typescript-eslint/prefer-namespace-keyword': 0, + '@typescript-eslint/prefer-nullish-coalescing': [ + 1, + { ignorePrimitives: { boolean: true, string: true } } + ], + '@typescript-eslint/prefer-optional-chain': 1, + '@typescript-eslint/prefer-promise-reject-errors': [1, { allowEmptyReject: true }], + '@typescript-eslint/prefer-readonly': 1, + '@typescript-eslint/prefer-readonly-parameter-types': 0, + '@typescript-eslint/prefer-reduce-type-parameter': 1, + '@typescript-eslint/prefer-regexp-exec': 1, + '@typescript-eslint/prefer-return-this-type': 0, + '@typescript-eslint/prefer-string-starts-ends-with': 1, + '@typescript-eslint/promise-function-async': 0, + '@typescript-eslint/require-array-sort-compare': 1, + '@typescript-eslint/restrict-plus-operands': 0, + '@typescript-eslint/restrict-template-expressions': 0, + '@typescript-eslint/sort-type-constituents': 0, + '@typescript-eslint/strict-boolean-expressions': 0, + '@typescript-eslint/switch-exhaustiveness-check': 1, + '@typescript-eslint/triple-slash-reference': [ + 1, + { path: 'never', types: 'never', lib: 'never' } + ], + '@typescript-eslint/typedef': 0, + '@typescript-eslint/unbound-method': 0, + '@typescript-eslint/unified-signatures': 0, + + // @typescript-eslint/eslint-plugin Extension Rules + // https://typescript-eslint.io/rules/#extension-rules + '@typescript-eslint/default-param-last': 0, + '@typescript-eslint/dot-notation': 1, + '@typescript-eslint/init-declarations': 0, + '@typescript-eslint/max-params': 0, + '@typescript-eslint/no-array-constructor': 0, + '@typescript-eslint/no-dupe-class-members': 0, + '@typescript-eslint/no-empty-function': 0, + '@typescript-eslint/no-implied-eval': 1, + '@typescript-eslint/no-invalid-this': 0, + '@typescript-eslint/no-loop-func': 0, + '@typescript-eslint/no-magic-numbers': 0, + '@typescript-eslint/no-redeclare': 1, + '@typescript-eslint/no-restricted-imports': [ + 1, + { + name: 'react', + importNames: ['default'], + message: 'Use named imports instead.' + }, + { + name: 'react-dom', + importNames: ['default'], + message: 'Use named imports instead.' + } + ], + '@typescript-eslint/no-shadow': 0, + '@typescript-eslint/no-unused-expressions': 0, + '@typescript-eslint/no-unused-private-class-members': 0, + '@typescript-eslint/no-unused-vars': [1, { ignoreRestSiblings: true }], + '@typescript-eslint/no-use-before-define': 0, + '@typescript-eslint/no-useless-constructor': 0, + '@typescript-eslint/only-throw-error': 1, + '@typescript-eslint/require-await': 1, + '@typescript-eslint/return-await': 1, + '@typescript-eslint/use-unknown-in-catch-callback-variable': 1 + } + }, + + { + name: 'test', + + files: ['test/**/*'], + + plugins: { + vitest, + 'jest-dom': jestDom, + 'testing-library': testingLibrary + }, + + rules: { + '@typescript-eslint/no-floating-promises': 1, + + // https://github.com/vitest-dev/eslint-plugin-vitest?tab=readme-ov-file#rules + 'vitest/consistent-test-filename': 0, + 'vitest/consistent-test-it': 1, + 'vitest/expect-expect': 0, + 'vitest/hoisted-apis-on-top': 1, + 'vitest/max-expects': 0, + 'vitest/max-nested-describe': 0, + 'vitest/no-alias-methods': 1, + 'vitest/no-commented-out-tests': 1, + 'vitest/no-conditional-expect': 1, + 'vitest/no-conditional-in-test': 0, + 'vitest/no-conditional-tests': 1, + 'vitest/no-disabled-tests': 0, + 'vitest/no-done-callback': 0, + 'vitest/no-duplicate-hooks': 1, + 'vitest/no-focused-tests': 1, + 'vitest/no-hooks': 1, + 'vitest/no-identical-title': 1, + 'vitest/no-import-node-test': 1, + 'vitest/no-importing-vitest-globals': 1, + 'vitest/no-interpolation-in-snapshots': 0, + 'vitest/no-large-snapshots': 0, + 'vitest/no-mocks-import': 1, + 'vitest/no-restricted-matchers': 0, + 'vitest/no-restricted-vi-methods': 0, + 'vitest/no-standalone-expect': 1, + 'vitest/no-test-prefixes': 0, + 'vitest/no-test-return-statement': 0, + 'vitest/padding-around-after-all-blocks': 0, + 'vitest/padding-around-after-each-blocks': 0, + 'vitest/padding-around-all': 0, + 'vitest/padding-around-before-all-blocks': 0, + 'vitest/padding-around-before-each-blocks': 0, + 'vitest/padding-around-describe-blocks': 0, + 'vitest/padding-around-expect-groups': 0, + 'vitest/padding-around-test-blocks': 0, + 'vitest/prefer-called-once': 1, + 'vitest/prefer-called-times': 0, + 'vitest/prefer-called-with': 0, + 'vitest/prefer-comparison-matcher': 1, + 'vitest/prefer-each': 1, + 'vitest/prefer-equality-matcher': 1, + 'vitest/prefer-expect-assertions': 0, + 'vitest/prefer-expect-resolves': 1, + 'vitest/prefer-hooks-in-order': 1, + 'vitest/prefer-hooks-on-top': 1, + 'vitest/prefer-importing-vitest-globals': 0, + 'vitest/prefer-lowercase-title': 0, + 'vitest/prefer-mock-promise-shorthand': 1, + 'vitest/prefer-snapshot-hint': 0, + 'vitest/prefer-spy-on': 1, + 'vitest/prefer-strict-boolean-matchers': 1, + 'vitest/prefer-strict-equal': 1, + 'vitest/prefer-to-be': 1, + 'vitest/prefer-to-be-falsy': 0, + 'vitest/prefer-to-be-object': 0, + 'vitest/prefer-to-be-truthy': 0, + 'vitest/prefer-to-contain': 1, + 'vitest/prefer-to-have-length': 1, + 'vitest/prefer-todo': 1, + 'vitest/prefer-vi-mocked': 1, + 'vitest/require-awaited-expect-poll': 1, + 'vitest/require-hook': 0, + 'vitest/require-import-vi-mock': 1, + 'vitest/require-local-test-context-for-concurrent-snapshots': 0, + 'vitest/require-mock-type-parameters': 0, + 'vitest/require-to-throw-message': 0, + 'vitest/require-top-level-describe': 0, + 'vitest/valid-describe-callback': 1, + 'vitest/valid-expect-in-promise': 1, + 'vitest/valid-expect': [1, { alwaysAwait: true }], + 'vitest/valid-title': 1, + 'vitest/warn-todo': 1, + + // https://github.com/testing-library/eslint-plugin-jest-dom#supported-rules + 'jest-dom/prefer-checked': 1, + 'jest-dom/prefer-empty': 1, + 'jest-dom/prefer-enabled-disabled': 1, + 'jest-dom/prefer-focus': 1, + 'jest-dom/prefer-in-document': 1, + 'jest-dom/prefer-required': 1, + 'jest-dom/prefer-to-have-attribute': 1, + 'jest-dom/prefer-to-have-class': 1, + 'jest-dom/prefer-to-have-style': 1, + 'jest-dom/prefer-to-have-text-content': 1, + 'jest-dom/prefer-to-have-value': 1, + + // eslint-plugin-testing-library Rules + // https://github.com/testing-library/eslint-plugin-testing-library#supported-rules + 'testing-library/await-async-events': 0, + 'testing-library/await-async-queries': 0, + 'testing-library/await-async-utils': 0, + 'testing-library/consistent-data-testid': 0, + 'testing-library/no-await-sync-events': 0, + 'testing-library/no-await-sync-queries': 0, + 'testing-library/no-container': 1, + 'testing-library/no-debugging-utils': 1, + 'testing-library/no-dom-import': 1, + 'testing-library/no-global-regexp-flag-in-query': 1, + 'testing-library/no-manual-cleanup': 0, + 'testing-library/no-node-access': 0, + 'testing-library/no-promise-in-fire-event': 0, + 'testing-library/no-render-in-lifecycle': 0, + 'testing-library/no-test-id-queries': 0, + 'testing-library/no-unnecessary-act': 1, + 'testing-library/no-wait-for-multiple-assertions': 1, + 'testing-library/no-wait-for-side-effects': 1, + 'testing-library/no-wait-for-snapshot': 0, + 'testing-library/prefer-explicit-assert': 1, + 'testing-library/prefer-find-by': 1, + 'testing-library/prefer-implicit-assert': 0, + 'testing-library/prefer-presence-queries': 0, + 'testing-library/prefer-query-by-disappearance': 1, + 'testing-library/prefer-query-matchers': 0, + 'testing-library/prefer-screen-queries': 0, + 'testing-library/prefer-user-event': 1, + 'testing-library/render-result-naming-convention': 0 + } + }, + + { + name: 'node', + + files: ['**/*.js'], + + rules: { + // Best Practices + 'default-param-last': 1, + // Possible Errors + 'no-console': 0, + 'no-undef': 1, + 'no-use-before-define': [1, { functions: false, classes: false, variables: false }] + } + }, + + { + name: 'markdown', + files: ['**/*.md'], + plugins: { + markdown + }, + language: 'markdown/commonmark', + rules: { + 'markdown/fenced-code-language': 1, + 'markdown/heading-increment': 1, + 'markdown/no-bare-urls': 1, + 'markdown/no-duplicate-definitions': 1, + 'markdown/no-duplicate-headings': 0, + 'markdown/no-empty-definitions': 1, + 'markdown/no-empty-images': 1, + 'markdown/no-empty-links': 1, + 'markdown/no-html': 0, + 'markdown/no-invalid-label-refs': 1, + 'markdown/no-missing-atx-heading-space': 1, + 'markdown/no-missing-label-refs': 1, + 'markdown/no-missing-link-fragments': 1, + 'markdown/no-multiple-h1': 1, + 'markdown/no-reference-like-urls': 1, + 'markdown/no-reversed-media-syntax': 1, + 'markdown/no-space-in-emphasis': 1, + 'markdown/no-unused-definitions': 1, + 'markdown/require-alt-text': 1, + 'markdown/table-column-count': 1 + } + } +]); diff --git a/examples/assets/css/bootstrap-theme.css b/examples/assets/css/bootstrap-theme.css deleted file mode 100644 index 52c29c9369..0000000000 --- a/examples/assets/css/bootstrap-theme.css +++ /dev/null @@ -1,98 +0,0 @@ -/*******************************/ -/* Navigatioin */ -/*******************************/ -.navbar-inverse { border-radius: 0; background:rgba(0, 0, 0, .8); border-bottom:1px solid rgba(255, 255, 255, 0.15); min-height:100px; padding-top:25px; margin-bottom:0;} -.navbar-inverse *:focus { outline: 0; } -@media (max-width: 767px) { - .navbar-inverse { background:rgba(0,0,0,.9); } -} - -.navbar-inverse .navbar-nav > li > a, -.navbar-inverse .navbar-nav > .open ul > a { color:rgba(255, 255, 255, .4); } - -.navbar-inverse .navbar-nav > .active > a, -.navbar-inverse .navbar-nav > .active > a:hover, -.navbar-inverse .navbar-nav > .active > a:focus { color: #fff; background:none ; } -.navbar-inverse .navbar-nav > .open > a{ background:none; color:white; } - -.navbar-inverse .navbar-nav>li>a:hover, -.navbar-inverse .navbar-nav>li>a:focus, -.navbar-inverse .navbar-nav>.open>a:hover, -.navbar-inverse .navbar-nav>.open>a:focus { background:none; color:white; } - -.navbar-inverse .navbar-nav > .active > a { background:none; color:white; } - -.navbar-inverse .navbar-brand { font-family: "Open sans", helvetica, arial; font-size: 24px; color:white; padding:0 0 0 15px; margin:12px 0 0 0; } - .navbar-inverse .navbar-brand img { margin-top:-8px;} - -.navbar-nav .dropdown-menu { - left:-5px; - font-size: 13px; - background-color: rgba(0, 0, 0, .7); - border: 0px none; - -webkit-border-radius: 0px; -moz-border-radius: 0px; border-radius: 0px; - -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); -} -.navbar-nav .dropdown-menu > li > a { color:rgba(255, 255, 255, .7); padding:7px 20px; } - .navbar-nav .dropdown-menu > li > a:hover, - .navbar-nav .dropdown-menu > li > a:focus, - .navbar-nav .dropdown-menu > .active > a:hover{ background: rgba(255, 255, 255, .1); color:white; } - -.navbar-nav .dropdown-menu > .active > a, -.navbar-nav .dropdown-menu > .active > a:focus { background: none; color:#fff; } - -.navbar-nav .btn { border:1px solid rgba(255, 255, 255, .2); margin-left:5px; margin-top:5px; padding-top:10px; padding-bottom:10px; } - -.navbar-nav a.btn:focus, -.navbar-nav a.btn:hover { border:1px solid rgba(255,255,255,.6); } - -.navbar-collapse { border:0 none; border-top:0 none; box-shadow: none; } -@media (max-width: 767px) { - .navbar-collapse ul { text-align: center; width:100%; padding-bottom:10px; } - .navbar-collapse ul .btn{ max-width:50%; margin:0 auto; } -} - -.navbar-static-top, -.navbar-fixed-top, -.navbar-fixed-bottom { border-radius: 0; } - - - - -/*******************************/ -/* Buttons */ -/*******************************/ -.btn-default, .btn-primary, .btn-success, .btn-action -.btn-info, .btn-warning, .btn-danger { - text-shadow: 0 2px 1px rgba(0, 0, 0, .2); -} - -.btn { padding: 10px 40px; font-weight: bold; border:0 none; -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; } -.btn-lg { padding: 15px 65px; font-size: 14px; font-weight:bold; } -.btn-default { text-shadow: none; background:transparent; color:rgba(50,50,50,.5); -webkit-box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.5); -moz-box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.5); box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.5); } - .btn-default:hover, - .btn-default:focus { color:rgba(50,50,50,.8); -webkit-box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.8); -moz-box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.8); box-shadow:inset 0px 0px 0px 3px rgba(50,50,50,.8); background: transparent; } - .btn-default:active, - .btn-default.active { color:#333; -webkit-box-shadow:inset 0px 0px 0px 3px #333; -moz-box-shadow:inset 0px 0px 0px 3px #333; box-shadow:inset 0px 0px 0px 3px #333; background: transparent; } - -.btn-action, -.btn-primary { color:#FFEFD7; background-image: -webkit-linear-gradient(top, #FF9B22 0%, #FF8C00 100%); background-image: linear-gradient(to bottom, #FF9B22 0%, #FF8C00 100%); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffFF9B22', endColorstr='#ffFF8C00', GradientType=0); filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); background-repeat: repeat-x; border:0 none; } - .btn-action:hover, - .btn-action:focus { color:#fff; background: #FF9B22; } - .btn-action:active { background: #FF8C00; } - - -/*******************************/ -/* Jumbotron */ -/*******************************/ -.jumbotron { color: inherit; background-color: #F7F5F4; padding-top:30px; padding-bottom:30px; margin-bottom:0; } -.container .jumbotron { -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; padding-left:40px; padding-right:40px; } - .jumbotron p { font-size:inherit; } - .jumbotron h2, .jumbotron h3, .jumbotron h4, - .jumbotron h5, .jumbotron h6 { line-height: 1.3em; } - - -/*******************************/ -/* Images */ -/*******************************/ -.img-rounded { -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; } \ No newline at end of file diff --git a/examples/assets/css/bootstrap.min.css b/examples/assets/css/bootstrap.min.css deleted file mode 100644 index da2a52878a..0000000000 --- a/examples/assets/css/bootstrap.min.css +++ /dev/null @@ -1,7 +0,0 @@ -/*! - * Bootstrap v3.0.3 (http://getbootstrap.com) - * Copyright 2013 Twitter, Inc. - * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) - */ - -/*! normalize.css v2.1.3 | MIT License | git.io/normalize */article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}audio,canvas,video{display:inline-block}audio:not([controls]){display:none;height:0}[hidden],template{display:none}html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}a{background:0 0}a:focus{outline:thin dotted}a:active,a:hover{outline:0}h1{font-size:2em;margin:.67em 0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}mark{background:#ff0;color:#000}code,kbd,pre,samp{font-family:monospace,serif;font-size:1em}pre{white-space:pre-wrap}q{quotes:"\201C" "\201D" "\2018" "\2019"}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:0}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}button,input,select,textarea{font-family:inherit;font-size:100%;margin:0}button,input{line-height:normal}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}textarea{overflow:auto;vertical-align:top}table{border-collapse:collapse;border-spacing:0}@media print{*{text-shadow:none!important;color:#000!important;background:transparent!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="javascript:"]:after,a[href^="#"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100%!important}@page{margin:2cm .5cm}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}select{background:#fff!important}.navbar{display:none}.table td,.table th{background-color:#fff!important}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table-bordered th,.table-bordered td{border:1px solid #ddd!important}}*,:before,:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:62.5%;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.428571429;color:#333;background-color:#fff}input,button,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#428bca;text-decoration:none}a:hover,a:focus{color:#2a6496;text-decoration:underline}a:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}img{vertical-align:middle}.img-responsive{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{padding:4px;line-height:1.428571429;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.img-circle{border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);border:0}h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}h1 small,h2 small,h3 small,h4 small,h5 small,h6 small,.h1 small,.h2 small,.h3 small,.h4 small,.h5 small,.h6 small,h1 .small,h2 .small,h3 .small,h4 .small,h5 .small,h6 .small,.h1 .small,.h2 .small,.h3 .small,.h4 .small,.h5 .small,.h6 .small{font-weight:400;line-height:1;color:#999}h1,.h1,h2,.h2,h3,.h3{margin-top:20px;margin-bottom:10px}h1 small,.h1 small,h2 small,.h2 small,h3 small,.h3 small,h1 .small,.h1 .small,h2 .small,.h2 .small,h3 .small,.h3 .small{font-size:65%}h4,.h4,h5,.h5,h6,.h6{margin-top:10px;margin-bottom:10px}h4 small,.h4 small,h5 small,.h5 small,h6 small,.h6 small,h4 .small,.h4 .small,h5 .small,.h5 .small,h6 .small,.h6 .small{font-size:75%}h1,.h1{font-size:36px}h2,.h2{font-size:30px}h3,.h3{font-size:24px}h4,.h4{font-size:18px}h5,.h5{font-size:14px}h6,.h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:200;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}small,.small{font-size:85%}cite{font-style:normal}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-muted{color:#999}.text-primary{color:#428bca}.text-primary:hover{color:#3071a9}.text-warning{color:#8a6d3b}.text-warning:hover{color:#66512c}.text-danger{color:#a94442}.text-danger:hover{color:#843534}.text-success{color:#3c763d}.text-success:hover{color:#2b542c}.text-info{color:#31708f}.text-info:hover{color:#245269}.bg-primary{color:#fff;background-color:#428bca}a.bg-primary:hover{background-color:#3071a9}.bg-warning{background-color:#fcf8e3}a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:hover{background-color:#e4b9b9}.bg-success{background-color:#dff0d8}a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:hover{background-color:#afd9ee}.page-header{padding-bottom:9px;margin:10px 0 20px;border-bottom:1px solid #eee}ul,ol{margin-top:0;margin-bottom:10px}ul ul,ol ul,ul ol,ol ol{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;list-style:none}.list-inline>li{display:inline-block;padding-left:5px;padding-right:5px}.list-inline>li:first-child{padding-left:0}dl{margin-top:0;margin-bottom:20px}dt,dd{line-height:1.428571429}dt{font-weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;clear:left;text-align:right;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[title],abbr[data-original-title]{cursor:help;border-bottom:1px dotted #999}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote p:last-child,blockquote ul:last-child,blockquote ol:last-child{margin-bottom:0}blockquote footer,blockquote small,blockquote .small{display:block;font-size:80%;line-height:1.428571429;color:#999}blockquote footer:before,blockquote small:before,blockquote .small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;border-right:5px solid #eee;border-left:0;text-align:right}.blockquote-reverse footer:before,blockquote.pull-right footer:before,.blockquote-reverse small:before,blockquote.pull-right small:before,.blockquote-reverse .small:before,blockquote.pull-right .small:before{content:''}.blockquote-reverse footer:after,blockquote.pull-right footer:after,.blockquote-reverse small:after,blockquote.pull-right small:after,.blockquote-reverse .small:after,blockquote.pull-right .small:after{content:'\00A0 \2014'}blockquote:before,blockquote:after{content:""}address{margin-bottom:20px;font-style:normal;line-height:1.428571429}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;white-space:nowrap;border-radius:4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.428571429;word-break:break-all;word-wrap:break-word;color:#333;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:transparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{margin-right:auto;margin-left:auto;padding-left:15px;padding-right:15px}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{margin-right:auto;margin-left:auto;padding-left:15px;padding-right:15px}.row{margin-left:-15px;margin-right:-15px}.col-xs-1,.col-sm-1,.col-md-1,.col-lg-1,.col-xs-2,.col-sm-2,.col-md-2,.col-lg-2,.col-xs-3,.col-sm-3,.col-md-3,.col-lg-3,.col-xs-4,.col-sm-4,.col-md-4,.col-lg-4,.col-xs-5,.col-sm-5,.col-md-5,.col-lg-5,.col-xs-6,.col-sm-6,.col-md-6,.col-lg-6,.col-xs-7,.col-sm-7,.col-md-7,.col-lg-7,.col-xs-8,.col-sm-8,.col-md-8,.col-lg-8,.col-xs-9,.col-sm-9,.col-md-9,.col-lg-9,.col-xs-10,.col-sm-10,.col-md-10,.col-lg-10,.col-xs-11,.col-sm-11,.col-md-11,.col-lg-11,.col-xs-12,.col-sm-12,.col-md-12,.col-lg-12{position:relative;min-height:1px;padding-left:15px;padding-right:15px}.col-xs-1,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9,.col-xs-10,.col-xs-11,.col-xs-12{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666666666666%}.col-xs-10{width:83.33333333333334%}.col-xs-9{width:75%}.col-xs-8{width:66.66666666666666%}.col-xs-7{width:58.333333333333336%}.col-xs-6{width:50%}.col-xs-5{width:41.66666666666667%}.col-xs-4{width:33.33333333333333%}.col-xs-3{width:25%}.col-xs-2{width:16.666666666666664%}.col-xs-1{width:8.333333333333332%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666666666666%}.col-xs-pull-10{right:83.33333333333334%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666666666666%}.col-xs-pull-7{right:58.333333333333336%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666666666667%}.col-xs-pull-4{right:33.33333333333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.666666666666664%}.col-xs-pull-1{right:8.333333333333332%}.col-xs-pull-0{right:0}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666666666666%}.col-xs-push-10{left:83.33333333333334%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666666666666%}.col-xs-push-7{left:58.333333333333336%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666666666667%}.col-xs-push-4{left:33.33333333333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.666666666666664%}.col-xs-push-1{left:8.333333333333332%}.col-xs-push-0{left:0}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666666666666%}.col-xs-offset-10{margin-left:83.33333333333334%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666666666666%}.col-xs-offset-7{margin-left:58.333333333333336%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666666666667%}.col-xs-offset-4{margin-left:33.33333333333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.666666666666664%}.col-xs-offset-1{margin-left:8.333333333333332%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-sm-10,.col-sm-11,.col-sm-12{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666666666666%}.col-sm-10{width:83.33333333333334%}.col-sm-9{width:75%}.col-sm-8{width:66.66666666666666%}.col-sm-7{width:58.333333333333336%}.col-sm-6{width:50%}.col-sm-5{width:41.66666666666667%}.col-sm-4{width:33.33333333333333%}.col-sm-3{width:25%}.col-sm-2{width:16.666666666666664%}.col-sm-1{width:8.333333333333332%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666666666666%}.col-sm-pull-10{right:83.33333333333334%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666666666666%}.col-sm-pull-7{right:58.333333333333336%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666666666667%}.col-sm-pull-4{right:33.33333333333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.666666666666664%}.col-sm-pull-1{right:8.333333333333332%}.col-sm-pull-0{right:0}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666666666666%}.col-sm-push-10{left:83.33333333333334%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666666666666%}.col-sm-push-7{left:58.333333333333336%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666666666667%}.col-sm-push-4{left:33.33333333333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.666666666666664%}.col-sm-push-1{left:8.333333333333332%}.col-sm-push-0{left:0}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666666666666%}.col-sm-offset-10{margin-left:83.33333333333334%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666666666666%}.col-sm-offset-7{margin-left:58.333333333333336%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666666666667%}.col-sm-offset-4{margin-left:33.33333333333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.666666666666664%}.col-sm-offset-1{margin-left:8.333333333333332%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-md-10,.col-md-11,.col-md-12{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666666666666%}.col-md-10{width:83.33333333333334%}.col-md-9{width:75%}.col-md-8{width:66.66666666666666%}.col-md-7{width:58.333333333333336%}.col-md-6{width:50%}.col-md-5{width:41.66666666666667%}.col-md-4{width:33.33333333333333%}.col-md-3{width:25%}.col-md-2{width:16.666666666666664%}.col-md-1{width:8.333333333333332%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666666666666%}.col-md-pull-10{right:83.33333333333334%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666666666666%}.col-md-pull-7{right:58.333333333333336%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666666666667%}.col-md-pull-4{right:33.33333333333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.666666666666664%}.col-md-pull-1{right:8.333333333333332%}.col-md-pull-0{right:0}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666666666666%}.col-md-push-10{left:83.33333333333334%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666666666666%}.col-md-push-7{left:58.333333333333336%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666666666667%}.col-md-push-4{left:33.33333333333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.666666666666664%}.col-md-push-1{left:8.333333333333332%}.col-md-push-0{left:0}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666666666666%}.col-md-offset-10{margin-left:83.33333333333334%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666666666666%}.col-md-offset-7{margin-left:58.333333333333336%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666666666667%}.col-md-offset-4{margin-left:33.33333333333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.666666666666664%}.col-md-offset-1{margin-left:8.333333333333332%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-lg-10,.col-lg-11,.col-lg-12{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666666666666%}.col-lg-10{width:83.33333333333334%}.col-lg-9{width:75%}.col-lg-8{width:66.66666666666666%}.col-lg-7{width:58.333333333333336%}.col-lg-6{width:50%}.col-lg-5{width:41.66666666666667%}.col-lg-4{width:33.33333333333333%}.col-lg-3{width:25%}.col-lg-2{width:16.666666666666664%}.col-lg-1{width:8.333333333333332%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666666666666%}.col-lg-pull-10{right:83.33333333333334%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666666666666%}.col-lg-pull-7{right:58.333333333333336%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666666666667%}.col-lg-pull-4{right:33.33333333333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.666666666666664%}.col-lg-pull-1{right:8.333333333333332%}.col-lg-pull-0{right:0}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666666666666%}.col-lg-push-10{left:83.33333333333334%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666666666666%}.col-lg-push-7{left:58.333333333333336%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666666666667%}.col-lg-push-4{left:33.33333333333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.666666666666664%}.col-lg-push-1{left:8.333333333333332%}.col-lg-push-0{left:0}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666666666666%}.col-lg-offset-10{margin-left:83.33333333333334%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666666666666%}.col-lg-offset-7{margin-left:58.333333333333336%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666666666667%}.col-lg-offset-4{margin-left:33.33333333333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.666666666666664%}.col-lg-offset-1{margin-left:8.333333333333332%}.col-lg-offset-0{margin-left:0}}table{max-width:100%;background-color:transparent}th{text-align:left}.table{width:100%;margin-bottom:20px}.table>thead>tr>th,.table>tbody>tr>th,.table>tfoot>tr>th,.table>thead>tr>td,.table>tbody>tr>td,.table>tfoot>tr>td{padding:8px;line-height:1.428571429;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>th,.table>caption+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>td,.table>thead:first-child>tr:first-child>td{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>thead>tr>th,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>tbody>tr>td,.table-condensed>tfoot>tr>td{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>tbody>tr>td,.table-bordered>tfoot>tr>td{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>thead>tr>td{border-bottom-width:2px}.table-striped>tbody>tr:nth-child(odd)>td,.table-striped>tbody>tr:nth-child(odd)>th{background-color:#f9f9f9}.table-hover>tbody>tr:hover>td,.table-hover>tbody>tr:hover>th{background-color:#f5f5f5}table col[class*=col-]{position:static;float:none;display:table-column}table td[class*=col-],table th[class*=col-]{position:static;float:none;display:table-cell}.table>thead>tr>td.active,.table>tbody>tr>td.active,.table>tfoot>tr>td.active,.table>thead>tr>th.active,.table>tbody>tr>th.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>tbody>tr.active>td,.table>tfoot>tr.active>td,.table>thead>tr.active>th,.table>tbody>tr.active>th,.table>tfoot>tr.active>th{background-color:#f5f5f5}.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover,.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.active:hover>th{background-color:#e8e8e8}.table>thead>tr>td.success,.table>tbody>tr>td.success,.table>tfoot>tr>td.success,.table>thead>tr>th.success,.table>tbody>tr>th.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>tbody>tr.success>td,.table>tfoot>tr.success>td,.table>thead>tr.success>th,.table>tbody>tr.success>th,.table>tfoot>tr.success>th{background-color:#dff0d8}.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover,.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>th{background-color:#d0e9c6}.table>thead>tr>td.warning,.table>tbody>tr>td.warning,.table>tfoot>tr>td.warning,.table>thead>tr>th.warning,.table>tbody>tr>th.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>tbody>tr.warning>td,.table>tfoot>tr.warning>td,.table>thead>tr.warning>th,.table>tbody>tr.warning>th,.table>tfoot>tr.warning>th{background-color:#fcf8e3}.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover,.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr.warning:hover>th{background-color:#faf2cc}.table>thead>tr>td.danger,.table>tbody>tr>td.danger,.table>tfoot>tr>td.danger,.table>thead>tr>th.danger,.table>tbody>tr>th.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>tbody>tr.danger>td,.table>tfoot>tr.danger>td,.table>thead>tr.danger>th,.table>tbody>tr.danger>th,.table>tfoot>tr.danger>th{background-color:#f2dede}.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover,.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th{background-color:#ebcccc}.table>thead>tr>td.info,.table>tbody>tr>td.info,.table>tfoot>tr>td.info,.table>thead>tr>th.info,.table>tbody>tr>th.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>tbody>tr.info>td,.table>tfoot>tr.info>td,.table>thead>tr.info>th,.table>tbody>tr.info>th,.table>tfoot>tr.info>th{background-color:#d9edf7}.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover,.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr.info:hover>th{background-color:#c4e3f3}@media (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;overflow-x:scroll;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd;-webkit-overflow-scrolling:touch}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>thead>tr>th,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tfoot>tr>td{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>thead>tr>th:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.table-responsive>.table-bordered>thead>tr>th:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>th,.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>td{border-bottom:0}}fieldset{padding:0;margin:0;border:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;margin-bottom:5px;font-weight:700}input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=radio],input[type=checkbox]{margin:4px 0 0;margin-top:1px \9;line-height:normal}input[type=file]{display:block}select[multiple],select[size]{height:auto}select optgroup{font-size:inherit;font-style:inherit;font-family:inherit}input[type=file]:focus,input[type=radio]:focus,input[type=checkbox]:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}input[type=number]::-webkit-outer-spin-button,input[type=number]::-webkit-inner-spin-button{height:auto}output{display:block;padding-top:7px;font-size:14px;line-height:1.428571429;color:#555}.form-control{display:block;width:100%;height:34px;padding:6px 12px;font-size:14px;line-height:1.428571429;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control:-moz-placeholder{color:#999}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee}textarea.form-control{height:auto}input[type=date]{line-height:34px}.form-group{margin-bottom:15px}.radio,.checkbox{display:block;min-height:20px;margin-top:10px;margin-bottom:10px;padding-left:20px}.radio label,.checkbox label{display:inline;font-weight:400;cursor:pointer}.radio input[type=radio],.radio-inline input[type=radio],.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox]{float:left;margin-left:-20px}.radio+.radio,.checkbox+.checkbox{margin-top:-5px}.radio-inline,.checkbox-inline{display:inline-block;padding-left:20px;margin-bottom:0;vertical-align:middle;font-weight:400;cursor:pointer}.radio-inline+.radio-inline,.checkbox-inline+.checkbox-inline{margin-top:0;margin-left:10px}input[type=radio][disabled],input[type=checkbox][disabled],.radio[disabled],.radio-inline[disabled],.checkbox[disabled],.checkbox-inline[disabled],fieldset[disabled] input[type=radio],fieldset[disabled] input[type=checkbox],fieldset[disabled] .radio,fieldset[disabled] .radio-inline,fieldset[disabled] .checkbox,fieldset[disabled] .checkbox-inline{cursor:not-allowed}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-height:30px}textarea.input-sm{height:auto}.input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-lg{height:46px;line-height:46px}textarea.input-lg{height:auto}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.has-feedback .form-control-feedback{position:absolute;top:25px;right:0;display:block;width:34px;height:34px;line-height:34px;text-align:center}.has-warning .help-block,.has-warning .control-label,.has-warning .radio,.has-warning .checkbox,.has-warning .radio-inline,.has-warning .checkbox-inline{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;border-color:#8a6d3b;background-color:#fcf8e3}.has-warning .form-control-feedback{color:#8a6d3b}.has-error .help-block,.has-error .control-label,.has-error .radio,.has-error .checkbox,.has-error .radio-inline,.has-error .checkbox-inline{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;border-color:#a94442;background-color:#f2dede}.has-error .form-control-feedback{color:#a94442}.has-success .help-block,.has-success .control-label,.has-success .radio,.has-success .checkbox,.has-success .radio-inline,.has-success .checkbox-inline{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;border-color:#3c763d;background-color:#dff0d8}.has-success .form-control-feedback{color:#3c763d}.form-control-static{margin-bottom:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .radio,.form-inline .checkbox{display:inline-block;margin-top:0;margin-bottom:0;padding-left:0;vertical-align:middle}.form-inline .radio input[type=radio],.form-inline .checkbox input[type=checkbox]{float:none;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .control-label,.form-horizontal .radio,.form-horizontal .checkbox,.form-horizontal .radio-inline,.form-horizontal .checkbox-inline{margin-top:0;margin-bottom:0;padding-top:7px}.form-horizontal .radio,.form-horizontal .checkbox{min-height:27px}.form-horizontal .form-group{margin-left:-15px;margin-right:-15px}.form-horizontal .form-control-static{padding-top:7px}@media (min-width:768px){.form-horizontal .control-label{text-align:right}}.form-horizontal .has-feedback .form-control-feedback{top:0;right:15px}.btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;cursor:pointer;background-image:none;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.428571429;border-radius:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.btn:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn:hover,.btn:focus{color:#333;text-decoration:none}.btn:active,.btn.active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default:hover,.btn-default:focus,.btn-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{color:#333;background-color:#ebebeb;border-color:#adadad}.btn-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{background-image:none}.btn-default.disabled,.btn-default[disabled],fieldset[disabled] .btn-default,.btn-default.disabled:hover,.btn-default[disabled]:hover,fieldset[disabled] .btn-default:hover,.btn-default.disabled:focus,.btn-default[disabled]:focus,fieldset[disabled] .btn-default:focus,.btn-default.disabled:active,.btn-default[disabled]:active,fieldset[disabled] .btn-default:active,.btn-default.disabled.active,.btn-default[disabled].active,fieldset[disabled] .btn-default.active{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#428bca;border-color:#357ebd}.btn-primary:hover,.btn-primary:focus,.btn-primary:active,.btn-primary.active,.open .dropdown-toggle.btn-primary{color:#fff;background-color:#3276b1;border-color:#285e8e}.btn-primary:active,.btn-primary.active,.open .dropdown-toggle.btn-primary{background-image:none}.btn-primary.disabled,.btn-primary[disabled],fieldset[disabled] .btn-primary,.btn-primary.disabled:hover,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary:hover,.btn-primary.disabled:focus,.btn-primary[disabled]:focus,fieldset[disabled] .btn-primary:focus,.btn-primary.disabled:active,.btn-primary[disabled]:active,fieldset[disabled] .btn-primary:active,.btn-primary.disabled.active,.btn-primary[disabled].active,fieldset[disabled] .btn-primary.active{background-color:#428bca;border-color:#357ebd}.btn-primary .badge{color:#428bca;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success:hover,.btn-success:focus,.btn-success:active,.btn-success.active,.open .dropdown-toggle.btn-success{color:#fff;background-color:#47a447;border-color:#398439}.btn-success:active,.btn-success.active,.open .dropdown-toggle.btn-success{background-image:none}.btn-success.disabled,.btn-success[disabled],fieldset[disabled] .btn-success,.btn-success.disabled:hover,.btn-success[disabled]:hover,fieldset[disabled] .btn-success:hover,.btn-success.disabled:focus,.btn-success[disabled]:focus,fieldset[disabled] .btn-success:focus,.btn-success.disabled:active,.btn-success[disabled]:active,fieldset[disabled] .btn-success:active,.btn-success.disabled.active,.btn-success[disabled].active,fieldset[disabled] .btn-success.active{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning:hover,.btn-warning:focus,.btn-warning:active,.btn-warning.active,.open .dropdown-toggle.btn-warning{color:#fff;background-color:#ed9c28;border-color:#d58512}.btn-warning:active,.btn-warning.active,.open .dropdown-toggle.btn-warning{background-image:none}.btn-warning.disabled,.btn-warning[disabled],fieldset[disabled] .btn-warning,.btn-warning.disabled:hover,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning:hover,.btn-warning.disabled:focus,.btn-warning[disabled]:focus,fieldset[disabled] .btn-warning:focus,.btn-warning.disabled:active,.btn-warning[disabled]:active,fieldset[disabled] .btn-warning:active,.btn-warning.disabled.active,.btn-warning[disabled].active,fieldset[disabled] .btn-warning.active{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger:hover,.btn-danger:focus,.btn-danger:active,.btn-danger.active,.open .dropdown-toggle.btn-danger{color:#fff;background-color:#d2322d;border-color:#ac2925}.btn-danger:active,.btn-danger.active,.open .dropdown-toggle.btn-danger{background-image:none}.btn-danger.disabled,.btn-danger[disabled],fieldset[disabled] .btn-danger,.btn-danger.disabled:hover,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger:hover,.btn-danger.disabled:focus,.btn-danger[disabled]:focus,fieldset[disabled] .btn-danger:focus,.btn-danger.disabled:active,.btn-danger[disabled]:active,fieldset[disabled] .btn-danger:active,.btn-danger.disabled.active,.btn-danger[disabled].active,fieldset[disabled] .btn-danger.active{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info:hover,.btn-info:focus,.btn-info:active,.btn-info.active,.open .dropdown-toggle.btn-info{color:#fff;background-color:#39b3d7;border-color:#269abc}.btn-info:active,.btn-info.active,.open .dropdown-toggle.btn-info{background-image:none}.btn-info.disabled,.btn-info[disabled],fieldset[disabled] .btn-info,.btn-info.disabled:hover,.btn-info[disabled]:hover,fieldset[disabled] .btn-info:hover,.btn-info.disabled:focus,.btn-info[disabled]:focus,fieldset[disabled] .btn-info:focus,.btn-info.disabled:active,.btn-info[disabled]:active,fieldset[disabled] .btn-info:active,.btn-info.disabled.active,.btn-info[disabled].active,fieldset[disabled] .btn-info.active{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-link{color:#428bca;font-weight:400;cursor:pointer;border-radius:0}.btn-link,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:hover,.btn-link:focus,.btn-link:active{border-color:transparent}.btn-link:hover,.btn-link:focus{color:#2a6496;text-decoration:underline;background-color:transparent}.btn-link[disabled]:hover,fieldset[disabled] .btn-link:hover,.btn-link[disabled]:focus,fieldset[disabled] .btn-link:focus{color:#999;text-decoration:none}.btn-lg{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%;padding-left:0;padding-right:0}.btn-block+.btn-block{margin-top:5px}input[type=submit].btn-block,input[type=reset].btn-block,input[type=button].btn-block{width:100%}.fade{opacity:0;-webkit-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}.collapsing{position:relative;height:0;overflow:hidden;-webkit-transition:height .35s ease;transition:height .35s ease}@font-face{font-family:'Glyphicons Halflings';src:url(http://github.com/fonts/glyphicons-halflings-regular.eot);src:url(http://github.com/fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'),url(http://github.com/fonts/glyphicons-halflings-regular.woff) format('woff'),url(http://github.com/fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(http://github.com/fonts/glyphicons-halflings-regular.svg#glyphicons-halflingsregular) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon-plus:before{content:"\2b"}.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px solid;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown{position:relative}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;list-style:none;font-size:14px;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175);background-clip:padding-box}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.428571429;color:#333;white-space:nowrap}.dropdown-menu>li>a:hover,.dropdown-menu>li>a:focus{text-decoration:none;color:#262626;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:hover,.dropdown-menu>.active>a:focus{color:#fff;text-decoration:none;outline:0;background-color:#428bca}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{color:#999}.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{text-decoration:none;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);cursor:not-allowed}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-right{left:auto;right:0}.dropdown-menu-left{left:0;right:auto}.dropdown-header{display:block;padding:3px 20px;font-size:12px;line-height:1.428571429;color:#999}.dropdown-backdrop{position:fixed;left:0;right:0;bottom:0;top:0;z-index:990}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{border-top:0;border-bottom:4px solid;content:""}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}@media (min-width:768px){.navbar-right .dropdown-menu{left:auto;right:0}.navbar-right .dropdown-menu-left{left:0;right:auto}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group>.btn,.btn-group-vertical>.btn{position:relative;float:left}.btn-group>.btn:hover,.btn-group-vertical>.btn:hover,.btn-group>.btn:focus,.btn-group-vertical>.btn:focus,.btn-group>.btn:active,.btn-group-vertical>.btn:active,.btn-group>.btn.active,.btn-group-vertical>.btn.active{z-index:2}.btn-group>.btn:focus,.btn-group-vertical>.btn:focus{outline:0}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar .btn-group,.btn-toolbar .input-group{float:left}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.btn-group>.btn-group{float:left}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group>.btn-group:first-child>.btn:last-child,.btn-group>.btn-group:first-child>.dropdown-toggle{border-bottom-right-radius:0;border-top-right-radius:0}.btn-group>.btn-group:last-child>.btn:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group-xs>.btn{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-group-sm>.btn{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-group-lg>.btn{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.btn-group>.btn+.dropdown-toggle{padding-left:8px;padding-right:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-left:12px;padding-right:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn .caret{margin-left:0}.btn-lg .caret{border-width:5px 5px 0;border-bottom-width:0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){border-bottom-left-radius:4px;border-top-right-radius:0;border-top-left-radius:0}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-right-radius:0;border-top-left-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{float:none;display:table-cell;width:1%}.btn-group-justified>.btn-group .btn{width:100%}[data-toggle=buttons]>.btn>input[type=radio],[data-toggle=buttons]>.btn>input[type=checkbox]{display:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-left:0;padding-right:0}.input-group .form-control{float:left;width:100%;margin-bottom:0}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn{height:auto}.input-group-addon,.input-group-btn,.input-group .form-control{display:table-cell}.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child),.input-group .form-control:not(:first-child):not(:last-child){border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.input-group-addon input[type=radio],.input-group-addon input[type=checkbox]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle),.input-group-btn:last-child>.btn-group:not(:last-child)>.btn{border-bottom-right-radius:0;border-top-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:first-child>.btn-group:not(:first-child)>.btn{border-bottom-left-radius:0;border-top-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:hover,.input-group-btn>.btn:focus,.input-group-btn>.btn:active{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{margin-left:-1px}.nav{margin-bottom:0;padding-left:0;list-style:none}.nav>li{position:relative;display:block}.nav>li>a{position:relative;display:block;padding:10px 15px}.nav>li>a:hover,.nav>li>a:focus{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#999}.nav>li.disabled>a:hover,.nav>li.disabled>a:focus{color:#999;text-decoration:none;background-color:transparent;cursor:not-allowed}.nav .open>a,.nav .open>a:hover,.nav .open>a:focus{background-color:#eee;border-color:#428bca}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.428571429;border:1px solid transparent;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:hover,.nav-tabs>li.active>a:focus{color:#555;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent;cursor:default}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{text-align:center;margin-bottom:5px}.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0}}.nav-tabs.nav-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-pills>li>a{border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:hover,.nav-pills>li.active>a:focus{color:#fff;background-color:#428bca}.nav-stacked>li{float:none}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li{float:none}.nav-justified>li>a{text-align:center;margin-bottom:5px}.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-right-radius:0;border-top-left-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}@media (min-width:768px){.navbar{border-radius:4px}}@media (min-width:768px){.navbar-header{float:left}}.navbar-collapse{max-height:340px;overflow-x:visible;padding-right:15px;padding-left:15px;border-top:1px solid transparent;box-shadow:inset 0 1px 0 rgba(255,255,255,.1);-webkit-overflow-scrolling:touch}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar-collapse{width:auto;border-top:0;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse,.navbar-fixed-bottom .navbar-collapse{padding-left:0;padding-right:0}}.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:0;margin-left:0}}.navbar-static-top{z-index:1000;border-width:0 0 1px}@media (min-width:768px){.navbar-static-top{border-radius:0}}.navbar-fixed-top,.navbar-fixed-bottom{position:fixed;right:0;left:0;z-index:1030}@media (min-width:768px){.navbar-fixed-top,.navbar-fixed-bottom{border-radius:0}}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.navbar-brand{float:left;padding:15px;font-size:18px;line-height:20px}.navbar-brand:hover,.navbar-brand:focus{text-decoration:none}.navbar-brand>.glyphicon{float:left;margin-top:-2px;margin-right:5px}@media (min-width:768px){.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;margin-right:15px;padding:9px 10px;margin-top:8px;margin-bottom:8px;background-color:transparent;background-image:none;border:1px solid transparent;border-radius:4px}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}@media (min-width:768px){.navbar-toggle{display:none}}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;box-shadow:none}.navbar-nav .open .dropdown-menu>li>a,.navbar-nav .open .dropdown-menu .dropdown-header{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:hover,.navbar-nav .open .dropdown-menu>li>a:focus{background-image:none}}@media (min-width:768px){.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}.navbar-nav.navbar-right:last-child{margin-right:-15px}}@media (min-width:768px){.navbar-left{float:left!important}.navbar-right{float:right!important}}.navbar-form{margin-left:-15px;margin-right:-15px;padding:10px 15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);margin-top:8px;margin-bottom:8px}@media (min-width:768px){.navbar-form .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .control-label{margin-bottom:0;vertical-align:middle}.navbar-form .radio,.navbar-form .checkbox{display:inline-block;margin-top:0;margin-bottom:0;padding-left:0;vertical-align:middle}.navbar-form .radio input[type=radio],.navbar-form .checkbox input[type=checkbox]{float:none;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}}@media (min-width:768px){.navbar-form{width:auto;border:0;margin-left:0;margin-right:0;padding-top:0;padding-bottom:0;-webkit-box-shadow:none;box-shadow:none}.navbar-form.navbar-right:last-child{margin-right:-15px}}.navbar-nav>li>.dropdown-menu{margin-top:0;border-top-right-radius:0;border-top-left-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{border-bottom-right-radius:0;border-bottom-left-radius:0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-left:15px;margin-right:15px}.navbar-text.navbar-right:last-child{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:hover,.navbar-default .navbar-brand:focus{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a{color:#777}.navbar-default .navbar-nav>li>a:hover,.navbar-default .navbar-nav>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:hover,.navbar-default .navbar-nav>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:hover,.navbar-default .navbar-nav>.disabled>a:focus{color:#ccc;background-color:transparent}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:hover,.navbar-default .navbar-toggle:focus{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:hover,.navbar-default .navbar-nav>.open>a:focus{background-color:#e7e7e7;color:#555}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#ccc;background-color:transparent}}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#999}.navbar-inverse .navbar-brand:hover,.navbar-inverse .navbar-brand:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-text{color:#999}.navbar-inverse .navbar-nav>li>a{color:#999}.navbar-inverse .navbar-nav>li>a:hover,.navbar-inverse .navbar-nav>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:hover,.navbar-inverse .navbar-nav>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:hover,.navbar-inverse .navbar-nav>.disabled>a:focus{color:#444;background-color:transparent}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:hover,.navbar-inverse .navbar-toggle:focus{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:hover,.navbar-inverse .navbar-nav>.open>a:focus{background-color:#080808;color:#fff}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#999}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#444;background-color:transparent}}.navbar-inverse .navbar-link{color:#999}.navbar-inverse .navbar-link:hover{color:#fff}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.breadcrumb>li{display:inline-block}.breadcrumb>li+li:before{content:"/\00a0";padding:0 5px;color:#ccc}.breadcrumb>.active{color:#999}.pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;line-height:1.428571429;text-decoration:none;color:#428bca;background-color:#fff;border:1px solid #ddd;margin-left:-1px}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-bottom-left-radius:4px;border-top-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{border-bottom-right-radius:4px;border-top-right-radius:4px}.pagination>li>a:hover,.pagination>li>span:hover,.pagination>li>a:focus,.pagination>li>span:focus{color:#2a6496;background-color:#eee;border-color:#ddd}.pagination>.active>a,.pagination>.active>span,.pagination>.active>a:hover,.pagination>.active>span:hover,.pagination>.active>a:focus,.pagination>.active>span:focus{z-index:2;color:#fff;background-color:#428bca;border-color:#428bca;cursor:default}.pagination>.disabled>span,.pagination>.disabled>span:hover,.pagination>.disabled>span:focus,.pagination>.disabled>a,.pagination>.disabled>a:hover,.pagination>.disabled>a:focus{color:#999;background-color:#fff;border-color:#ddd;cursor:not-allowed}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-bottom-left-radius:6px;border-top-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-bottom-right-radius:6px;border-top-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-bottom-left-radius:3px;border-top-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-bottom-right-radius:3px;border-top-right-radius:3px}.pager{padding-left:0;margin:20px 0;list-style:none;text-align:center}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;border-radius:15px}.pager li>a:hover,.pager li>a:focus{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:hover,.pager .disabled>a:focus,.pager .disabled>span{color:#999;background-color:#fff;cursor:not-allowed}.label{display:inline;padding:.2em .6em .3em;font-size:75%;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25em}.label[href]:hover,.label[href]:focus{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.btn .label{position:relative;top:-1px}.label-default{background-color:#999}.label-default[href]:hover,.label-default[href]:focus{background-color:gray}.label-primary{background-color:#428bca}.label-primary[href]:hover,.label-primary[href]:focus{background-color:#3071a9}.label-success{background-color:#5cb85c}.label-success[href]:hover,.label-success[href]:focus{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:hover,.label-info[href]:focus{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:hover,.label-warning[href]:focus{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:hover,.label-danger[href]:focus{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;font-weight:700;color:#fff;line-height:1;vertical-align:baseline;white-space:nowrap;text-align:center;background-color:#999;border-radius:10px}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}a.badge:hover,a.badge:focus{color:#fff;text-decoration:none;cursor:pointer}a.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#428bca;background-color:#fff}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding:30px;margin-bottom:30px;color:inherit;background-color:#eee}.jumbotron h1,.jumbotron .h1{color:inherit}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.container .jumbotron{border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding-top:48px;padding-bottom:48px}.container .jumbotron{padding-left:60px;padding-right:60px}.jumbotron h1,.jumbotron .h1{font-size:63px}}.thumbnail{display:block;padding:4px;margin-bottom:20px;line-height:1.428571429;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.thumbnail>img,.thumbnail a>img{display:block;max-width:100%;height:auto;margin-left:auto;margin-right:auto}a.thumbnail:hover,a.thumbnail:focus,a.thumbnail.active{border-color:#428bca}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;margin-bottom:20px;border:1px solid transparent;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert .alert-link{font-weight:700}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable{padding-right:35px}.alert-dismissable .close{position:relative;top:-2px;right:-21px;color:inherit}.alert-success{background-color:#dff0d8;border-color:#d6e9c6;color:#3c763d}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{background-color:#d9edf7;border-color:#bce8f1;color:#31708f}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{background-color:#f2dede;border-color:#ebccd1;color:#a94442}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{overflow:hidden;height:20px;margin-bottom:20px;background-color:#f5f5f5;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#428bca;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;transition:width .6s ease}.progress-striped .progress-bar{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-size:40px 40px}.progress.active .progress-bar{-webkit-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media,.media-body{overflow:hidden;zoom:1}.media,.media .media{margin-top:15px}.media:first-child{margin-top:0}.media-object{display:block}.media-heading{margin:0 0 5px}.media>.pull-left{margin-right:10px}.media>.pull-right{margin-left:10px}.media-list{padding-left:0;list-style:none}.list-group{margin-bottom:20px;padding-left:0}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{border-top-right-radius:4px;border-top-left-radius:4px}.list-group-item:last-child{margin-bottom:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}a.list-group-item{color:#555}a.list-group-item .list-group-item-heading{color:#333}a.list-group-item:hover,a.list-group-item:focus{text-decoration:none;background-color:#f5f5f5}a.list-group-item.active,a.list-group-item.active:hover,a.list-group-item.active:focus{z-index:2;color:#fff;background-color:#428bca;border-color:#428bca}a.list-group-item.active .list-group-item-heading,a.list-group-item.active:hover .list-group-item-heading,a.list-group-item.active:focus .list-group-item-heading{color:inherit}a.list-group-item.active .list-group-item-text,a.list-group-item.active:hover .list-group-item-text,a.list-group-item.active:focus .list-group-item-text{color:#e1edf7}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:hover,a.list-group-item-success:focus{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:hover,a.list-group-item-success.active:focus{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:hover,a.list-group-item-warning:focus{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:hover,a.list-group-item-warning.active:focus{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:hover,a.list-group-item-danger:focus{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:hover,a.list-group-item-danger.active:focus{color:#fff;background-color:#a94442;border-color:#a94442}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:hover,a.list-group-item-info:focus{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:hover,a.list-group-item-info.active:focus{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-body{padding:15px}.panel>.list-group{margin-bottom:0}.panel>.list-group .list-group-item{border-width:1px 0}.panel>.list-group .list-group-item:first-child{border-top-right-radius:0;border-top-left-radius:0}.panel>.list-group .list-group-item:last-child{border-bottom:0}.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.panel>.table,.panel>.table-responsive>.table{margin-bottom:0}.panel>.table>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive>.table>tbody:last-child>tr:last-child td:first-child,.panel>.table>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive>.table>tfoot:last-child>tr:last-child td:first-child,.panel>.table>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive>.table>tbody:last-child>tr:last-child th:first-child,.panel>.table>tfoot:last-child>tr:last-child th:first-child,.panel>.table-responsive>.table>tfoot:last-child>tr:last-child th:first-child{border-bottom-left-radius:3px}.panel>.table>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive>.table>tbody:last-child>tr:last-child td:last-child,.panel>.table>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive>.table>tfoot:last-child>tr:last-child td:last-child,.panel>.table>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive>.table>tbody:last-child>tr:last-child th:last-child,.panel>.table>tfoot:last-child>tr:last-child th:last-child,.panel>.table-responsive>.table>tfoot:last-child>tr:last-child th:last-child{border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive{border-top:1px solid #ddd}.panel>.table>tbody:first-child th,.panel>.table>tbody:first-child td{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.panel>.table-bordered>thead>tr:last-child>th,.panel>.table-responsive>.table-bordered>thead>tr:last-child>th,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th,.panel>.table-bordered>thead>tr:last-child>td,.panel>.table-responsive>.table-bordered>thead>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td{border-bottom:0}.panel>.table-responsive{border:0;margin-bottom:0}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;border-top-right-radius:3px;border-top-left-radius:3px}.panel-heading>.dropdown .dropdown-toggle{color:inherit}.panel-title{margin-top:0;margin-bottom:0;font-size:16px;color:inherit}.panel-title>a{color:inherit}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel-group .panel{margin-bottom:0;border-radius:4px;overflow:hidden}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading{border-bottom:0}.panel-group .panel-heading+.panel-collapse .panel-body{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse .panel-body{border-top-color:#ddd}.panel-default>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#428bca}.panel-primary>.panel-heading{color:#fff;background-color:#428bca;border-color:#428bca}.panel-primary>.panel-heading+.panel-collapse .panel-body{border-top-color:#428bca}.panel-primary>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#428bca}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse .panel-body{border-top-color:#d6e9c6}.panel-success>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#d6e9c6}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse .panel-body{border-top-color:#faebcc}.panel-warning>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse .panel-body{border-top-color:#ebccd1}.panel-danger>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#ebccd1}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse .panel-body{border-top-color:#bce8f1}.panel-info>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#bce8f1}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;border-radius:6px}.well-sm{padding:9px;border-radius:3px}.close{float:right;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;opacity:.2;filter:alpha(opacity=20)}.close:hover,.close:focus{color:#000;text-decoration:none;cursor:pointer;opacity:.5;filter:alpha(opacity=50)}button.close{padding:0;cursor:pointer;background:0 0;border:0;-webkit-appearance:none}.modal-open{overflow:hidden}.modal{display:none;overflow:auto;overflow-y:scroll;position:fixed;top:0;right:0;bottom:0;left:0;z-index:1050;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);transform:translate(0,-25%);-webkit-transition:-webkit-transform .3s ease-out;-moz-transition:-moz-transform .3s ease-out;-o-transition:-o-transform .3s ease-out;transition:transform .3s ease-out}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);transform:translate(0,0)}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;border:1px solid #999;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5);background-clip:padding-box;outline:0}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;background-color:#000}.modal-backdrop.fade{opacity:0;filter:alpha(opacity=0)}.modal-backdrop.in{opacity:.5;filter:alpha(opacity=50)}.modal-header{padding:15px;border-bottom:1px solid #e5e5e5;min-height:16.428571429px}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.428571429}.modal-body{position:relative;padding:20px}.modal-footer{margin-top:15px;padding:19px 20px 20px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-left:5px;margin-bottom:0}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1030;display:block;visibility:visible;font-size:12px;line-height:1.4;opacity:0;filter:alpha(opacity=0)}.tooltip.in{opacity:.9;filter:alpha(opacity=90)}.tooltip.top{margin-top:-3px;padding:5px 0}.tooltip.right{margin-left:3px;padding:0 5px}.tooltip.bottom{margin-top:3px;padding:5px 0}.tooltip.left{margin-left:-3px;padding:0 5px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;text-decoration:none;background-color:#000;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{bottom:0;left:5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-right .tooltip-arrow{bottom:0;right:5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-left .tooltip-arrow{top:0;left:5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-right .tooltip-arrow{top:0;right:5px;border-width:0 5px 5px;border-bottom-color:#000}.popover{position:absolute;top:0;left:0;z-index:1010;display:none;max-width:276px;padding:1px;text-align:left;background-color:#fff;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2);white-space:normal}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{margin:0;padding:8px 14px;font-size:14px;font-weight:400;line-height:18px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover .arrow,.popover .arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover .arrow{border-width:11px}.popover .arrow:after{border-width:10px;content:""}.popover.top .arrow{left:50%;margin-left:-11px;border-bottom-width:0;border-top-color:#999;border-top-color:rgba(0,0,0,.25);bottom:-11px}.popover.top .arrow:after{content:" ";bottom:1px;margin-left:-10px;border-bottom-width:0;border-top-color:#fff}.popover.right .arrow{top:50%;left:-11px;margin-top:-11px;border-left-width:0;border-right-color:#999;border-right-color:rgba(0,0,0,.25)}.popover.right .arrow:after{content:" ";left:1px;bottom:-10px;border-left-width:0;border-right-color:#fff}.popover.bottom .arrow{left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25);top:-11px}.popover.bottom .arrow:after{content:" ";top:1px;margin-left:-10px;border-top-width:0;border-bottom-color:#fff}.popover.left .arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left .arrow:after{content:" ";right:1px;border-right-width:0;border-left-color:#fff;bottom:-10px}.carousel{position:relative}.carousel-inner{position:relative;overflow:hidden;width:100%}.carousel-inner>.item{display:none;position:relative;-webkit-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>img,.carousel-inner>.item>a>img{display:block;max-width:100%;height:auto;line-height:1}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;left:0;bottom:0;width:15%;opacity:.5;filter:alpha(opacity=50);font-size:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-control.left{background-image:-webkit-linear-gradient(left,color-stop(rgba(0,0,0,.5) 0),color-stop(rgba(0,0,0,.0001) 100%));background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1)}.carousel-control.right{left:auto;right:0;background-image:-webkit-linear-gradient(left,color-stop(rgba(0,0,0,.0001) 0),color-stop(rgba(0,0,0,.5) 100%));background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1)}.carousel-control:hover,.carousel-control:focus{outline:0;color:#fff;text-decoration:none;opacity:.9;filter:alpha(opacity=90)}.carousel-control .icon-prev,.carousel-control .icon-next,.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right{position:absolute;top:50%;z-index:5;display:inline-block}.carousel-control .icon-prev,.carousel-control .glyphicon-chevron-left{left:50%}.carousel-control .icon-next,.carousel-control .glyphicon-chevron-right{right:50%}.carousel-control .icon-prev,.carousel-control .icon-next{width:20px;height:20px;margin-top:-10px;margin-left:-10px;font-family:serif}.carousel-control .icon-prev:before{content:'\2039'}.carousel-control .icon-next:before{content:'\203a'}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;margin-left:-30%;padding-left:0;list-style:none;text-align:center}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;border:1px solid #fff;border-radius:10px;cursor:pointer;background-color:#000 \9;background-color:rgba(0,0,0,0)}.carousel-indicators .active{margin:0;width:12px;height:12px;background-color:#fff}.carousel-caption{position:absolute;left:15%;right:15%;bottom:20px;z-index:10;padding-top:20px;padding-bottom:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-caption .btn{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicons-chevron-left,.carousel-control .glyphicons-chevron-right,.carousel-control .icon-prev,.carousel-control .icon-next{width:30px;height:30px;margin-top:-15px;margin-left:-15px;font-size:30px}.carousel-caption{left:20%;right:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.clearfix:before,.clearfix:after,.container:before,.container:after,.container-fluid:before,.container-fluid:after,.row:before,.row:after,.form-horizontal .form-group:before,.form-horizontal .form-group:after,.btn-toolbar:before,.btn-toolbar:after,.btn-group-vertical>.btn-group:before,.btn-group-vertical>.btn-group:after,.nav:before,.nav:after,.navbar:before,.navbar:after,.navbar-header:before,.navbar-header:after,.navbar-collapse:before,.navbar-collapse:after,.pager:before,.pager:after,.panel-body:before,.panel-body:after,.modal-footer:before,.modal-footer:after{content:" ";display:table}.clearfix:after,.container:after,.container-fluid:after,.row:after,.form-horizontal .form-group:after,.btn-toolbar:after,.btn-group-vertical>.btn-group:after,.nav:after,.navbar:after,.navbar-header:after,.navbar-collapse:after,.pager:after,.panel-body:after,.modal-footer:after{clear:both}.center-block{display:block;margin-left:auto;margin-right:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.hidden{display:none!important;visibility:hidden!important}.affix{position:fixed}@-ms-viewport{width:device-width}.visible-xs,tr.visible-xs,th.visible-xs,td.visible-xs{display:none!important}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table}tr.visible-xs{display:table-row!important}th.visible-xs,td.visible-xs{display:table-cell!important}}.visible-sm,tr.visible-sm,th.visible-sm,td.visible-sm{display:none!important}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table}tr.visible-sm{display:table-row!important}th.visible-sm,td.visible-sm{display:table-cell!important}}.visible-md,tr.visible-md,th.visible-md,td.visible-md{display:none!important}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table}tr.visible-md{display:table-row!important}th.visible-md,td.visible-md{display:table-cell!important}}.visible-lg,tr.visible-lg,th.visible-lg,td.visible-lg{display:none!important}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table}tr.visible-lg{display:table-row!important}th.visible-lg,td.visible-lg{display:table-cell!important}}@media (max-width:767px){.hidden-xs,tr.hidden-xs,th.hidden-xs,td.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm,tr.hidden-sm,th.hidden-sm,td.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md,tr.hidden-md,th.hidden-md,td.hidden-md{display:none!important}}@media (min-width:1200px){.hidden-lg,tr.hidden-lg,th.hidden-lg,td.hidden-lg{display:none!important}}.visible-print,tr.visible-print,th.visible-print,td.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table}tr.visible-print{display:table-row!important}th.visible-print,td.visible-print{display:table-cell!important}}@media print{.hidden-print,tr.hidden-print,th.hidden-print,td.hidden-print{display:none!important}} diff --git a/examples/assets/css/codemirror.css b/examples/assets/css/codemirror.css deleted file mode 100644 index 515a608874..0000000000 --- a/examples/assets/css/codemirror.css +++ /dev/null @@ -1,239 +0,0 @@ -/* BASICS */ - -.CodeMirror { - /* Set height, width, borders, and global font properties here */ - font-family: monospace; -} -.CodeMirror-scroll { - /* Set scrolling behaviour here */ - overflow: auto; -} - -/* PADDING */ - -.CodeMirror-lines { - padding: 14px 0; /* Vertical padding around content */ -} -.CodeMirror pre { - padding: 0 14px; /* Horizontal padding of content */ -} - -.CodeMirror-scrollbar-filler { - background-color: white; /* The little square between H and V scrollbars */ -} - -/* GUTTER */ - -.CodeMirror-gutters { - border-right: 1px solid #ddd; - background-color: #f7f7f7; -} -.CodeMirror-linenumbers {} - .CodeMirror-linenumber { - padding: 0 3px 0 5px; - min-width: 20px; - text-align: right; - color: #999; - } - - /* CURSOR */ - - .CodeMirror div.CodeMirror-cursor { - border-left: 1px solid black; - } - /* Shown when moving in bi-directional text */ - .CodeMirror div.CodeMirror-secondarycursor { - border-left: 1px solid silver; - } - .CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor { - width: auto; - border: 0; - background: transparent; - background: rgba(0, 200, 0, .4); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#6600c800, endColorstr=#4c00c800); - } - /* Kludge to turn off filter in ie9+, which also accepts rgba */ - .CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor:not(#nonsense_id) { - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); - } - /* Can style cursor different in overwrite (non-insert) mode */ - .CodeMirror div.CodeMirror-cursor.CodeMirror-overwrite {} - - /* DEFAULT THEME */ - - .cm-s-default .cm-keyword {color: #708;} - .cm-s-default .cm-atom {color: #219;} - .cm-s-default .cm-number {color: #164;} - .cm-s-default .cm-def {color: #00f;} - .cm-s-default .cm-variable {color: black;} - .cm-s-default .cm-variable-2 {color: #05a;} - .cm-s-default .cm-variable-3 {color: #085;} - .cm-s-default .cm-property {color: black;} - .cm-s-default .cm-operator {color: black;} - .cm-s-default .cm-comment {color: #a50;} - .cm-s-default .cm-string {color: #a11;} - .cm-s-default .cm-string-2 {color: #f50;} - .cm-s-default .cm-meta {color: #555;} - .cm-s-default .cm-error {color: #f00;} - .cm-s-default .cm-qualifier {color: #555;} - .cm-s-default .cm-builtin {color: #30a;} - .cm-s-default .cm-bracket {color: #997;} - .cm-s-default .cm-tag {color: #170;} - .cm-s-default .cm-attribute {color: #00c;} - .cm-s-default .cm-header {color: blue;} - .cm-s-default .cm-quote {color: #090;} - .cm-s-default .cm-hr {color: #999;} - .cm-s-default .cm-link {color: #00c;} - - .cm-negative {color: #d44;} - .cm-positive {color: #292;} - .cm-header, .cm-strong {font-weight: bold;} - .cm-em {font-style: italic;} - .cm-emstrong {font-style: italic; font-weight: bold;} - .cm-link {text-decoration: underline;} - - .cm-invalidchar {color: #f00;} - - div.CodeMirror span.CodeMirror-matchingbracket {color: #0f0;} - div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;} - - /* STOP */ - - /* The rest of this file contains styles related to the mechanics of - the editor. You probably shouldn't touch them. */ - - .CodeMirror { - line-height: 1; - position: relative; - overflow: hidden; - } - - .CodeMirror-scroll { - /* 30px is the magic margin used to hide the element's real scrollbars */ - /* See overflow: hidden in .CodeMirror, and the paddings in .CodeMirror-sizer */ - margin-bottom: -30px; margin-right: -30px; - padding-bottom: 30px; padding-right: 30px; - height: 100%; - outline: none; /* Prevent dragging from highlighting the element */ - position: relative; - } - .CodeMirror-sizer { - position: relative; - } - - /* The fake, visible scrollbars. Used to force redraw during scrolling - before actuall scrolling happens, thus preventing shaking and - flickering artifacts. */ - .CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler { - position: absolute; - z-index: 6; - display: none; - } - .CodeMirror-vscrollbar { - right: 0; top: 0; - overflow-x: hidden; - overflow-y: scroll; - } - .CodeMirror-hscrollbar { - bottom: 0; left: 0; - overflow-y: hidden; - overflow-x: scroll; - } - .CodeMirror-scrollbar-filler { - right: 0; bottom: 0; - z-index: 6; - } - - .CodeMirror-gutters { - position: absolute; left: 0; top: 0; - height: 100%; - z-index: 3; - } - .CodeMirror-gutter { - height: 100%; - display: inline-block; - /* Hack to make IE7 behave */ - *zoom:1; - *display:inline; - } - .CodeMirror-gutter-elt { - position: absolute; - cursor: default; - z-index: 4; - } - - .CodeMirror-lines { - cursor: text; - } - .CodeMirror pre { - /* Reset some styles that the rest of the page might have set */ - -moz-border-radius: 0; -webkit-border-radius: 0; -o-border-radius: 0; border-radius: 0; - border-width: 0; - background: transparent; - font-family: inherit; - font-size: inherit; - margin: 0; - white-space: pre; - word-wrap: normal; - line-height: inherit; - color: inherit; - z-index: 2; - position: relative; - overflow: visible; - } - .CodeMirror-wrap pre { - word-wrap: break-word; - white-space: pre-wrap; - word-break: normal; - } - .CodeMirror-linebackground { - position: absolute; - left: 0; right: 0; top: 0; bottom: 0; - z-index: 0; - } - - .CodeMirror-linewidget { - position: relative; - z-index: 2; - overflow: auto; - } - - .CodeMirror-wrap .CodeMirror-scroll { - overflow-x: hidden; - } - - .CodeMirror-measure { - position: absolute; - width: 100%; height: 0px; - overflow: hidden; - visibility: hidden; - } - .CodeMirror-measure pre { position: static; } - - .CodeMirror div.CodeMirror-cursor { - position: absolute; - visibility: hidden; - border-right: none; - width: 0; - } - .CodeMirror-focused div.CodeMirror-cursor { - visibility: visible; - } - - .CodeMirror-selected { background: #d9d9d9; } - .CodeMirror-focused .CodeMirror-selected { background: #d7d4f0; } - - .cm-searching { - background: #ffa; - background: rgba(255, 255, 0, .4); - } - - /* IE7 hack to prevent it from returning funny offsetTops on the spans */ - .CodeMirror span { *vertical-align: text-bottom; } - - @media print { - /* Hide the cursor when printing */ - .CodeMirror div.CodeMirror-cursor { - visibility: hidden; - } - } diff --git a/examples/assets/css/examples.css b/examples/assets/css/examples.css deleted file mode 100644 index 3cf684c3e8..0000000000 --- a/examples/assets/css/examples.css +++ /dev/null @@ -1,489 +0,0 @@ -.cm-s-solarized-light { - background-color: #f8f5ec; - color: #637c84; -} - -.cm-s-solarized-light .emphasis { - font-weight: bold; -} - -.cm-s-solarized-light .dotted { - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-light .CodeMirror-gutter { - background-color: #eee8d5; - border-right: 3px solid #eee8d5; -} - -.cm-s-solarized-light .CodeMirror-gutter .CodeMirror-gutter-text { - color: #93a1a1; -} - -.cm-s-solarized-light .CodeMirror-cursor { - border-left-color: #002b36 !important; -} - -.cm-s-solarized-light .CodeMirror-matchingbracket { - color: #002b36; - background-color: #eee8d5; - box-shadow: 0 0 10px #eee8d5; - font-weight: bold; -} - -.cm-s-solarized-light .CodeMirror-nonmatchingbracket { - color: #002b36; - background-color: #eee8d5; - box-shadow: 0 0 10px #eee8d5; - font-weight: bold; - color: #dc322f; - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-light span.cm-keyword { - color: #268bd2; -} - -.cm-s-solarized-light span.cm-atom { - color: #2aa198; -} - -.cm-s-solarized-light span.cm-number { - color: #586e75; -} - -.cm-s-solarized-light span.cm-def { - color: #637c84; -} - -.cm-s-solarized-light span.cm-variable { - color: #637c84; -} - -.cm-s-solarized-light span.cm-variable-2 { - color: #b58900; -} - -.cm-s-solarized-light span.cm-variable-3 { - color: #cb4b16; -} - -.cm-s-solarized-light span.cm-comment { - color: #93a1a1; -} - -.cm-s-solarized-light span.cm-property { - color: #637c84; -} - -.cm-s-solarized-light span.cm-operator { - color: #657b83; -} - -.cm-s-solarized-light span.cm-string { - color: #36958e; -} - -.cm-s-solarized-light span.cm-error { - font-weight: bold; - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-light span.cm-bracket { - color: #cb4b16; -} - -.cm-s-solarized-light span.cm-tag { - color: #657b83; -} - -.cm-s-solarized-light span.cm-attribute { - color: #586e75; - font-weight: bold; -} - -.cm-s-solarized-light span.cm-meta { - color: #268bd2; -} - -.cm-s-solarized-dark { - background-color: #002b36; - color: #839496; -} - -.cm-s-solarized-dark .emphasis { - font-weight: bold; -} - -.cm-s-solarized-dark .dotted { - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-dark .CodeMirror-gutter { - background-color: #073642; - border-right: 3px solid #073642; -} - -.cm-s-solarized-dark .CodeMirror-gutter .CodeMirror-gutter-text { - color: #586e75; -} - -.cm-s-solarized-dark .CodeMirror-cursor { - border-left-color: #fdf6e3 !important; -} - -.cm-s-solarized-dark .CodeMirror-matchingbracket { - color: #fdf6e3; - background-color: #073642; - box-shadow: 0 0 10px #073642; - font-weight: bold; -} - -.cm-s-solarized-dark .CodeMirror-nonmatchingbracket { - color: #fdf6e3; - background-color: #073642; - box-shadow: 0 0 10px #073642; - font-weight: bold; - color: #dc322f; - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-dark span.cm-keyword { - color: #839496; - font-weight: bold; -} - -.cm-s-solarized-dark span.cm-atom { - color: #2aa198; -} - -.cm-s-solarized-dark span.cm-number { - color: #93a1a1; -} - -.cm-s-solarized-dark span.cm-def { - color: #268bd2; -} - -.cm-s-solarized-dark span.cm-variable { - color: #cb4b16; -} - -.cm-s-solarized-dark span.cm-variable-2 { - color: #cb4b16; -} - -.cm-s-solarized-dark span.cm-variable-3 { - color: #cb4b16; -} - -.cm-s-solarized-dark span.cm-comment { - color: #586e75; -} - -.cm-s-solarized-dark span.cm-property { - color: #b58900; -} - -.cm-s-solarized-dark span.cm-operator { - color: #839496; -} - -.cm-s-solarized-dark span.cm-string { - color: #6c71c4; -} - -.cm-s-solarized-dark span.cm-error { - font-weight: bold; - border-bottom: 1px dotted #cb4b16; -} - -.cm-s-solarized-dark span.cm-bracket { - color: #cb4b16; -} - -.cm-s-solarized-dark span.cm-tag { - color: #839496; -} - -.cm-s-solarized-dark span.cm-attribute { - color: #93a1a1; - font-weight: bold; -} - -.cm-s-solarized-dark span.cm-meta { - color: #268bd2; -} - -* { - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - box-sizing: border-box; - border: none; - margin: 0; - padding: 0; -} - - -div.CodeMirror pre,div.CodeMirror-linenumber,code { - font-family: 'source-code-pro', Menlo, Consolas, 'Courier New', monospace; - font-size: 13px; - line-height: 1.5; -} - -div.CodeMirror-linenumber { - text-align: right; -} - -.CodeMirror,div.CodeMirror-gutters,div.highlight { - border: none; -} - -.CodeMirror-readonly div.CodeMirror-cursor { - visibility: hidden; -} - -small code,li code,p code { - color: #555; - background-color: rgba(0,0,0,0.04); - padding: 1px 3px; -} - -.cm-s-default span.cm-string-2 { - color: inherit; -} - -.playground:after { - content: ""; - display: table; - clear: both; -} - -.playground-tab { - border-bottom: none !important; - border-radius: 3px 3px 0 0; - padding: 6px 8px; - font-size: 12px; - font-weight: bold; - color: #c2c0bc; - background-color: #f1ede4; - display: inline-block; - cursor: pointer; -} - -.playgroundCode,.playground-tab,.playgroundPreview { - border: 1px solid rgba(16,16,16,0.1); -} - -.playground-tab-active { - color: #222; -} - -.playgroundCode { - border-radius: 0 3px 3px 3px; - float: left; - overflow: hidden; - width : 100%; -} - -.playgroundPreview { - background-color: white; - border-radius: 3px; - float: left; - padding: 15px 20px; - width:100%; -} - -.playgroundError { - color: #c5695c; - font-size: 15px; -} - -.MarkdownEditor textarea { - width: 100%; - height: 100px; -} - -.MarkdownEditor .content { - white-space: pre-wrap; -} - -.hll { - background-color: #f7ebc6; - border-left: 5px solid #f7d87c; - display: block; - margin-left: -14px; - margin-right: -14px; - padding-left: 9px; -} - -.highlight .javascript .err { - background-color: transparent; - color: inherit; -} - -.highlight { - position: relative; - margin-bottom: 14px; - padding: 30px 14px 14px; - border: none; - border-radius: 0; - overflow: auto; -} - -.highlight pre { - padding: 0; - margin-top: 0; - margin-bottom: 0; - background-color: transparent; - border: 0; -} - -.highlight pre code { - display: block; - background: none; - padding: 0; -} - -.highlight pre .lineno { - display: inline-block; - width: 22px; - padding-right: 5px; - margin-right: 10px; - color: #bebec5; - text-align: right; -} - -.highlight:after { - position: absolute; - top: 0; - right: 0; - left: 0; - padding: 3px 7px; - font-size: 12px; - font-weight: bold; - color: #c2c0bc; - background-color: #f1ede4; - content: "Code"; -} - -.downloadCenter { - text-align: center; - margin-top: 20px; - margin-bottom: 25px; -} - -.downloadSection:hover { - text-decoration: none !important; -} - -@media screen and (max-width: 960px) { - .nav-main { - position: static; - } - - .container { - padding-top: 0; - } -} - -.post { - margin-bottom: 30px; -} - -.pagination { - margin-bottom: 30px; - width: 100%; - overflow: hidden; -} - -.pagination .next { - float: right; -} - -div[data-twttr-id] iframe { - margin: 10px auto !important; - width: 100% !important; -} - -.three-column:after { - content: ""; - display: table; - clear: both; -} - -.three-column>ul { - float: left; - margin-left: 30px; - width: 190px; -} - -.three-column>ul:first-child { - margin-left: 20px; -} - -.documentationContent .subHeader { - font-size: 24px; -} - -.documentationContent h2 { - margin-top: 30px; -} - -.documentationContent blockquote { - padding: 15px 30px 15px 15px; - margin: 20px 0; - background-color: rgba(204,122,111,0.1); - border-left: 5px solid rgba(191,87,73,0.2); -} - -.documentationContent blockquote h4 { - margin-top: 0; -} - -.documentationContent blockquote p { - margin-bottom: 0; -} - -.documentationContent blockquote p:first-child { - font-weight: bold; - font-size: 17.5px; - line-height: 20px; - margin-top: 0; - text-rendering: optimizelegibility; -} - -.docs-prevnext { - padding-top: 40px; - padding-bottom: 40px; -} - -.jsxCompiler { - margin: 0 auto; - padding-top: 20px; - width: 1220px; -} - -.jsxCompiler label.compiler-option { - display: block; - margin-top: 5px; -} - -.jsxCompiler #jsxCompiler { - margin-top: 20px; -} - -.jsxCompiler .playgroundPreview { - padding: 0; - width: 600px; -} - -.jsxCompiler .playgroundPreview pre { - font-family: 'source-code-pro', Menlo, Consolas, 'Courier New', monospace; - font-size: 13px; - line-height: 1.5; -} - -.jsxCompiler .playgroundError { - padding: 15px 20px; -} diff --git a/examples/assets/css/highlight.css b/examples/assets/css/highlight.css deleted file mode 100644 index 2728fc0edc..0000000000 --- a/examples/assets/css/highlight.css +++ /dev/null @@ -1,409 +0,0 @@ -.highlight pre code { - color: #637c84; -} - -.highlight { - color: #333333; - background: #f8f5ec; -} - -.highlight .c { - color: #93a1a1; -} - - -.highlight .g { - color: #637c84; -} - -/* Generic */ - -.highlight .k { - color: #859900; -} - -/* Keyword */ - -.highlight .l { - color: #637c84; -} - -/* Literal */ - -.highlight .n { - color: #637c84; -} - -/* Name */ - -.highlight .o { - color: #859900; -} - -/* Operator */ - -.highlight .x { - color: #cc7a6f; -} - -/* Other */ - -.highlight .p { - color: #637c84; -} - -/* Punctuation */ - -.highlight .cm { - color: #93a1a1; -} - -/* Comment.Multiline */ - -.highlight .cp { - color: #859900; -} - -/* Comment.Preproc */ - -.highlight .c1 { - color: #93a1a1; -} - -/* Comment.Single */ - -.highlight .cs { - color: #859900; -} - -/* Comment.Special */ - -.highlight .gd { - color: #36958e; -} - -/* Generic.Deleted */ - -.highlight .ge { - font-style: italic; - color: #637c84; -} - -/* Generic.Emph */ - -.highlight .gr { - color: #dc322f; -} - -/* Generic.Error */ - -.highlight .gh { - color: #cc7a6f; -} - -/* Generic.Heading */ - -.highlight .gi { - color: #859900; -} - -/* Generic.Inserted */ - -.highlight .go { - color: #637c84; -} - -/* Generic.Output */ - -.highlight .gp { - color: #637c84; -} - -/* Generic.Prompt */ - -.highlight .gs { - font-weight: bold; - color: #637c84; -} - -/* Generic.Strong */ - -.highlight .gu { - color: #cc7a6f; -} - -/* Generic.Subheading */ - -.highlight .gt { - color: #637c84; -} - -/* Generic.Traceback */ - -.highlight .kc { - color: #cc7a6f; -} - -/* Keyword.Constant */ - -.highlight .kd { - color: #268bd2; -} - -/* Keyword.Declaration */ - -.highlight .kn { - color: #859900; -} - -/* Keyword.Namespace */ - -.highlight .kp { - color: #859900; -} - -/* Keyword.Pseudo */ - -.highlight .kr { - color: #268bd2; -} - -/* Keyword.Reserved */ - -.highlight .kt { - color: #dc322f; -} - -/* Keyword.Type */ - -.highlight .ld { - color: #637c84; -} - -/* Literal.Date */ - -.highlight .m { - color: #36958e; -} - -/* Literal.Number */ - -.highlight .s { - color: #36958e; -} - -/* Literal.String */ - -.highlight .na { - color: #637c84; -} - -/* Name.Attribute */ - -.highlight .nb { - color: #b58900; -} - -/* Name.Builtin */ - -.highlight .nc { - color: #268bd2; -} - -/* Name.Class */ - -.highlight .no { - color: #cc7a6f; -} - -/* Name.Constant */ - -.highlight .nd { - color: #268bd2; -} - -/* Name.Decorator */ - -.highlight .ni { - color: #cc7a6f; -} - -/* Name.Entity */ - -.highlight .ne { - color: #cc7a6f; -} - -/* Name.Exception */ - -.highlight .nf { - color: #268bd2; -} - -/* Name.Function */ - -.highlight .nl { - color: #637c84; -} - -/* Name.Label */ - -.highlight .nn { - color: #637c84; -} - -/* Name.Namespace */ - -.highlight .nx { - color: #637c84; -} - -/* Name.Other */ - -.highlight .py { - color: #637c84; -} - -/* Name.Property */ - -.highlight .nt { - color: #268bd2; -} - -/* Name.Tag */ - -.highlight .nv { - color: #268bd2; -} - -/* Name.Variable */ - -.highlight .ow { - color: #859900; -} - -/* Operator.Word */ - -.highlight .w { - color: #637c84; -} - -/* Text.Whitespace */ - -.highlight .mf { - color: #36958e; -} - -/* Literal.Number.Float */ - -.highlight .mh { - color: #36958e; -} - -/* Literal.Number.Hex */ - -.highlight .mi { - color: #36958e; -} - -/* Literal.Number.Integer */ - -.highlight .mo { - color: #36958e; -} - -/* Literal.Number.Oct */ - -.highlight .sb { - color: #93a1a1; -} - -/* Literal.String.Backtick */ - -.highlight .sc { - color: #36958e; -} - -/* Literal.String.Char */ - -.highlight .sd { - color: #637c84; -} - -/* Literal.String.Doc */ - -.highlight .s2 { - color: #36958e; -} - -/* Literal.String.Double */ - -.highlight .se { - color: #cc7a6f; -} - -/* Literal.String.Escape */ - -.highlight .sh { - color: #637c84; -} - -/* Literal.String.Heredoc */ - -.highlight .si { - color: #36958e; -} - -/* Literal.String.Interpol */ - -.highlight .sx { - color: #36958e; -} - -/* Literal.String.Other */ - -.highlight .sr { - color: #dc322f; -} - -/* Literal.String.Regex */ - -.highlight .s1 { - color: #36958e; -} - -/* Literal.String.Single */ - -.highlight .ss { - color: #36958e; -} - -/* Literal.String.Symbol */ - -.highlight .bp { - color: #268bd2; -} - -/* Name.Builtin.Pseudo */ - -.highlight .vc { - color: #268bd2; -} - -/* Name.Variable.Class */ - -.highlight .vg { - color: #268bd2; -} - -/* Name.Variable.Global */ - -.highlight .vi { - color: #268bd2; -} - -/* Name.Variable.Instance */ - -.highlight .il { - color: #36958e; -} diff --git a/examples/assets/css/main.css b/examples/assets/css/main.css deleted file mode 100644 index bd17dcf55c..0000000000 --- a/examples/assets/css/main.css +++ /dev/null @@ -1,563 +0,0 @@ -/* Header */ -#head { - background: #70B9B0 url(http://github.com/images/grid.png); - min-height: 400px; - text-align: center; - padding-top: 100px; - color: white; - font-family: 'Roboto', sans-serif, Helvetica, Arial; - font-weight: 300; -} - -.main-grid { - background : url(http://github.com/images/datagrid1.png) no-repeat center; - background-position-y:inherit; - height : 600px; -} - -.main-logo { - background: url(http://github.com/images/AdazzleLogoWhite.png) no-repeat center; - height: 89px; - margin-bottom: -50px -} - -.grid-examples { - position : relative; - top:200px; - width : 500px; - display : block; - margin-left: auto; - margin-right : auto; - background-color:white; - padding: 5px; - background-color: white; - border-radius: 5px; - -moz-border-radius: 5px; - -webkit-border-radius: 5px; - border: 3px solid #eee; -} - -.grid-examples h3 { - text-align : center; -} -.grid-examples ul { - -moz-column-count : 2; - -moz-column-gap :20px; - -webkit-column-gap:20px; - -webkit-column-count:2; - column-count: 2; - column-gap: 20px; -} - -#head.secondary { - height: 100px; - min-height: 100px; - padding-top: 0px; -} - -#head .lead { - font-family: "Open sans", Helvetica, Arial; - font-size: 70px; - margin-bottom: 6px; - color: white; - line-height: 1.15em; -} - -#head .tagline { - color: rgba(255,255,255,0.75); - margin-bottom: 25px; - font-size: 30px; -} - -#head .tagline a { - color: #fff; -} - -#head .btn { - margin-bottom: 10px; -} - -#head .btn-default { - text-shadow: none; - background: transparent; - color: rgba(255,255,255,.5); - -webkit-box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.5); - -moz-box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.5); - box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.5); - background: transparent; -} - -#head .btn-default:hover, -#head .btn-default:focus { - color: rgba(255,255,255,.8); - -webkit-box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.8); - -moz-box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.8); - box-shadow: inset 0px 0px 0px 3px rgba(255,255,255,.8); - background: transparent; -} - -#head .btn-default:active, -#head .btn-default.active { - color: #fff; - -webkit-box-shadow: inset 0px 0px 0px 3px #fff; - -moz-box-shadow: inset 0px 0px 0px 3px #fff; - box-shadow: inset 0px 0px 0px 3px #fff; - background: transparent; -} - -.header-logo{ - width: 100px; - margin-top: -9px; - margin-right: -4px; -} - -@media (max-width: 767px) { - #head { - min-height: 420px; - padding-top: 160px; - } - - #head .lead { - font-size: 34px; - } -} - -.navbar { - background-color : rgba(0, 0, 0, .8); -} - -.navbar a { - color : white; -} - - -/* Autohide navbar */ -.slideUp { - top: -100px; -} - -.headroom { - -webkit-transition: all 0.4s ease-out; - -moz-transition: all 0.4s ease-out; - -o-transition: all 0.4s ease-out; - transition: all 0.4s ease-out; -} - - -/* Highlights (in jumbotron in most cases) */ -.highlight { - margin-top: 40px; -} - -.h-caption { - text-align: center; -} - -.h-caption i { - display: block; - font-size: 54px; - color: #382526; - margin-bottom: 36px; -} - -.h-caption h4 { - color: #382526; - font-size: 16px; - font-weight: bold; - margin-bottom: 20px; -} - -.h-body { -} - -body{ - font-family: 'Roboto', sans-serif, Helvetica, Arial; -} - - -/* Typography */ -h1, h2, h3, h4, h5, h6 { - font-family: 'Roboto', sans-serif, Helvetica, Arial; -} - -h1, .h1, h2, .h2, h3, .h3 { - margin-top: 30px; -} - -blockquote { - font-style: italic; - font-family: Georgia; - color: #999; - margin: 30px 0 30px; -} - -label { - color: #777; -} - -.thin { - font-weight: 300; -} - -.page-title { - margin-top: 20px; - font-weight: 300; -} - -.text-muted { - color: #888; -} - -.breadcrumb { - background: none; - padding: 0; - margin: 30px 0 0px 0; -} - -ul.list-spaces li { - margin-bottom: 10px; -} - -/* Helpers */ -.container-full { - margin: 0 auto; - width: 100%; -} - -.top-space { - margin-top: 60px; -} - -.top-margin { - margin-top: 20px; -} - -img { - max-width: 100%; -} - -img.pull-right { - margin-left: 10px; -} - -img.pull-left { - margin-right: 10px; -} - -#map { - width: 100%; - height: 280px; -} - -#social { - margin-top: 50px; - margin-bottom: 50px; -} - -#social .wrapper { - width: 340px; - margin: 0 auto; -} - -/* Main content block */ -.maincontent { -} - -/* Sidebars */ -.sidebar { - padding-top: 36px; - padding-bottom: 30px; -} - -.sidebar .widget { - margin-bottom: 20px; -} - -.sidebar h1, .sidebar .h1, .sidebar h2, .sidebar .h2, .sidebar h3, .sidebar .h3 { - margin-top: 20px; -} - -/* Footer */ -.footer1 { - background: #232323; - padding: 30px 0 0 0; - font-size: 12px; - color: #999; -} - -.footer1 a { - color: #ccc; -} - -.footer1 a:hover { - color: #fff; -} - -.footer1 .widget { - margin-bottom: 30px; -} - -.footer1 .widget-title { - font-size: 17px; - font-weight: bold; - color: #ccc; - margin: 0 0 20px; -} - -.footer1 .entry-meta { - border-top: 1px solid #ccc; - border-bottom: 1px solid #ccc; - margin: 0 0 35px 0; - padding: 2px 0; - color: #888888; - font-size: 12px; - font-size: 0.75rem; -} - -.footer1 .entry-meta a { - color: #333333; -} - -.footer1 .entry-meta .meta-in { - border-top: 1px solid #ccc; - border-bottom: 1px solid #ccc; - padding: 10px 0; -} - -.follow-me-icons { - font-size: 30px; -} - -.follow-me-icons i { - float: left; - margin: 0 10px 0 0; -} - -.footer2 { - background: #191919; - padding: 15px 0; - color: #777; - font-size: 12px; -} - -.footer2 a { - color: #aaa; -} - -.footer2 a:hover { - color: #fff; -} - -.footer2 p { - margin: 0; -} - -.widget-simplenav { - margin-left: -5px; -} - -.widget-simplenav a { - margin: 0 5px; -} - -.demo-btn{ - display:block; - margin-left:auto - margin-right:auto; -} - -@media (min-width: 992px) { - .bs-docs-sidebar .nav>.active>ul { - display:block - } - - .bs-docs-sidebar.affix,.bs-docs-sidebar.affix-bottom { - width: 213px - } - - .bs-docs-sidebar.affix { - position: fixed; - top: 100px - } - - .bs-docs-sidebar.affix-bottom { - position: absolute - } - - .bs-docs-sidebar.affix .bs-docs-sidenav,.bs-docs-sidebar.affix-bottom .bs-docs-sidenav { - margin-top: 0; - margin-bottom: 0 - } -} - -@media (min-width: 1200px) { - .bs-docs-sidebar.affix,.bs-docs-sidebar.affix-bottom { - width:263px - } -} - - -@media (min-width: 768px) { - .bs-docs-sidebar { - padding-left:20px - } -} - -.bs-docs-sidenav { - margin-top: 20px; - margin-bottom: 20px -} - -.bs-docs-sidebar .nav>li>a { - display: block; - padding: 4px 20px; - font-size: 13px; - font-weight: 500; - color: #767676 -} - -.bs-docs-sidebar .nav>li>a:focus,.bs-docs-sidebar .nav>li>a:hover { - padding-left: 19px; - color: #563d7c; - text-decoration: none; - background-color: transparent; - border-left: 1px solid #563d7c -} - -.bs-docs-sidebar .nav>.active:focus>a,.bs-docs-sidebar .nav>.active:hover>a,.bs-docs-sidebar .nav>.active>a { - padding-left: 18px; - font-weight: 700; - color: #563d7c; - background-color: transparent; - border-left: 2px solid #563d7c -} - -.bs-docs-sidebar .nav .nav { - display: none; - padding-bottom: 10px -} - -.bs-docs-sidebar .nav .nav>li>a { - padding-top: 1px; - padding-bottom: 1px; - padding-left: 30px; - font-size: 12px; - font-weight: 400 -} - -.bs-docs-sidebar .nav .nav>li>a:focus,.bs-docs-sidebar .nav .nav>li>a:hover { - padding-left: 29px -} - -.bs-docs-sidebar .nav .nav>.active:focus>a,.bs-docs-sidebar .nav .nav>.active:hover>a,.bs-docs-sidebar .nav .nav>.active>a { - padding-left: 28px; - font-weight: 500 -} - -.top-space { - margin-top : 60px -} - -.docs-section{ - margin-bottom : 60px -} - - -.code-block .javascript .err { - background-color: transparent; - color: inherit -} - -.code-block { - position: relative; - margin-bottom: 14px; - padding: 30px 14px 14px; - border: none; - border-radius: 0; - overflow: auto -} - -.code-block pre { - padding: 0; - margin-top: 0; - margin-bottom: 0; - background-color: transparent; - border: 0 -} - -.code-block pre code { - display: block; - background: none; - padding: 0 -} - -.code-block pre .lineno { - display: inline-block; - width: 22px; - padding-right: 5px; - margin-right: 10px; - color: #bebec5; - text-align: right -} - -.code-block:after { - position: absolute; - top: 0; - right: 0; - left: 0; - padding: 3px 7px; - font-size: 12px; - font-weight: bold; - color: #c2c0bc; - background-color: #f1ede4; - -} - -.code-block.function:after{ - content: "Function Definition" -} - -.code-block.flow:after { - content: "Flow interface definitions" -} - -.code-block.js:after { - content: "Code" -} - -.code-block.function{ - color: #333333; - background: #f8f5ec; -} - -.code-block.js{ - color: #333333; - background: lemonchiffon; -} - -.code-block.flow{ - color: blue; - background-color : rgba(226, 141, 49, 0.1); -} - -.github-ribbon { - position: absolute; - top: 0; - right: 0; - border: 0; - width: 149px; - height: 149px; -} - -code.tab1{ - margin-left:3px; -} -code.tab2{ - margin-left:6px; -} -code.tab3{ - margin-left:9px; -} -code.tab4{ - margin-left:12px; -} diff --git a/examples/assets/images/AdazzleHeaderLogo.png b/examples/assets/images/AdazzleHeaderLogo.png deleted file mode 100644 index 466ff10009..0000000000 Binary files a/examples/assets/images/AdazzleHeaderLogo.png and /dev/null differ diff --git a/examples/assets/images/AdazzleLogo.png b/examples/assets/images/AdazzleLogo.png deleted file mode 100644 index cdc0e4f3d7..0000000000 Binary files a/examples/assets/images/AdazzleLogo.png and /dev/null differ diff --git a/examples/assets/images/AdazzleLogoWhite.png b/examples/assets/images/AdazzleLogoWhite.png deleted file mode 100644 index d0b9ee2fcc..0000000000 Binary files a/examples/assets/images/AdazzleLogoWhite.png and /dev/null differ diff --git a/examples/assets/images/bg2.png b/examples/assets/images/bg2.png deleted file mode 100644 index 8ccd4c5689..0000000000 Binary files a/examples/assets/images/bg2.png and /dev/null differ diff --git a/examples/assets/images/datagrid1.png b/examples/assets/images/datagrid1.png deleted file mode 100644 index 428483c89f..0000000000 Binary files a/examples/assets/images/datagrid1.png and /dev/null differ diff --git a/examples/assets/images/grid.png b/examples/assets/images/grid.png deleted file mode 100644 index 2c1eeaa2d8..0000000000 Binary files a/examples/assets/images/grid.png and /dev/null differ diff --git a/examples/assets/images/gridme.png b/examples/assets/images/gridme.png deleted file mode 100644 index 74655b1058..0000000000 Binary files a/examples/assets/images/gridme.png and /dev/null differ diff --git a/examples/assets/images/gridme_@2X.png b/examples/assets/images/gridme_@2X.png deleted file mode 100644 index 56af5b63e0..0000000000 Binary files a/examples/assets/images/gridme_@2X.png and /dev/null differ diff --git a/examples/assets/images/gt_favicon.png b/examples/assets/images/gt_favicon.png deleted file mode 100644 index bac684b0ac..0000000000 Binary files a/examples/assets/images/gt_favicon.png and /dev/null differ diff --git a/examples/assets/images/logo.png b/examples/assets/images/logo.png deleted file mode 100644 index 6d58ead3cd..0000000000 Binary files a/examples/assets/images/logo.png and /dev/null differ diff --git a/examples/assets/images/rdatagrid2.png b/examples/assets/images/rdatagrid2.png deleted file mode 100644 index 8d9ddffe05..0000000000 Binary files a/examples/assets/images/rdatagrid2.png and /dev/null differ diff --git a/examples/assets/images/rsz_adazzlelogo.png b/examples/assets/images/rsz_adazzlelogo.png deleted file mode 100644 index eccd0135a1..0000000000 Binary files a/examples/assets/images/rsz_adazzlelogo.png and /dev/null differ diff --git a/examples/assets/js/ReactPlayground.js b/examples/assets/js/ReactPlayground.js deleted file mode 100644 index 45b47c97e1..0000000000 --- a/examples/assets/js/ReactPlayground.js +++ /dev/null @@ -1,232 +0,0 @@ -var IS_MOBILE = ( - navigator.userAgent.match(/Android/i) - || navigator.userAgent.match(/webOS/i) - || navigator.userAgent.match(/iPhone/i) - || navigator.userAgent.match(/iPad/i) - || navigator.userAgent.match(/iPod/i) - || navigator.userAgent.match(/BlackBerry/i) - || navigator.userAgent.match(/Windows Phone/i) -); -var IS_MOBILE = ( - navigator.userAgent.match(/Android/i) - || navigator.userAgent.match(/webOS/i) - || navigator.userAgent.match(/iPhone/i) - || navigator.userAgent.match(/iPad/i) - || navigator.userAgent.match(/iPod/i) - || navigator.userAgent.match(/BlackBerry/i) - || navigator.userAgent.match(/Windows Phone/i) -); - -var CodeMirrorEditor = React.createClass({ - propTypes: { - lineNumbers: React.PropTypes.bool, - onChange: React.PropTypes.func - }, - getDefaultProps: function() { - return { - lineNumbers: false - }; - }, - componentDidMount: function() { - if (IS_MOBILE) return; - - this.editor = CodeMirror.fromTextArea(this.refs.editor.getDOMNode(), { - mode: 'javascript', - lineNumbers: this.props.lineNumbers, - lineWrapping: true, - smartIndent: false, // javascript mode does bad things with jsx indents - matchBrackets: true, - theme: 'solarized-light', - readOnly: this.props.readOnly - }); - this.editor.on('change', this.handleChange); - }, - - componentDidUpdate: function() { - if (this.props.readOnly) { - this.editor.setValue(this.props.codeText); - } - }, - - handleChange: function() { - if (!this.props.readOnly) { - this.props.onChange && this.props.onChange(this.editor.getValue()); - } - }, - - render: function() { - // wrap in a div to fully contain CodeMirror - var editor; - - if (IS_MOBILE) { - editor =
{this.props.codeText}
; - } else { - editor = "; - support.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue; -})(); -var strundefined = typeof undefined; - - - -support.focusinBubbles = "onfocusin" in window; - - -var - rkeyEvent = /^key/, - rmouseEvent = /^(?:mouse|pointer|contextmenu)|click/, - rfocusMorph = /^(?:focusinfocus|focusoutblur)$/, - rtypenamespace = /^([^.]*)(?:\.(.+)|)$/; - -function returnTrue() { - return true; -} - -function returnFalse() { - return false; -} - -function safeActiveElement() { - try { - return document.activeElement; - } catch ( err ) { } -} - -/* - * Helper functions for managing events -- not part of the public interface. - * Props to Dean Edwards' addEvent library for many of the ideas. - */ -jQuery.event = { - - global: {}, - - add: function( elem, types, handler, data, selector ) { - - var handleObjIn, eventHandle, tmp, - events, t, handleObj, - special, handlers, type, namespaces, origType, - elemData = data_priv.get( elem ); - - // Don't attach events to noData or text/comment nodes (but allow plain objects) - if ( !elemData ) { - return; - } - - // Caller can pass in an object of custom data in lieu of the handler - if ( handler.handler ) { - handleObjIn = handler; - handler = handleObjIn.handler; - selector = handleObjIn.selector; - } - - // Make sure that the handler has a unique ID, used to find/remove it later - if ( !handler.guid ) { - handler.guid = jQuery.guid++; - } - - // Init the element's event structure and main handler, if this is the first - if ( !(events = elemData.events) ) { - events = elemData.events = {}; - } - if ( !(eventHandle = elemData.handle) ) { - eventHandle = elemData.handle = function( e ) { - // Discard the second event of a jQuery.event.trigger() and - // when an event is called after a page has unloaded - return typeof jQuery !== strundefined && jQuery.event.triggered !== e.type ? - jQuery.event.dispatch.apply( elem, arguments ) : undefined; - }; - } - - // Handle multiple events separated by a space - types = ( types || "" ).match( rnotwhite ) || [ "" ]; - t = types.length; - while ( t-- ) { - tmp = rtypenamespace.exec( types[t] ) || []; - type = origType = tmp[1]; - namespaces = ( tmp[2] || "" ).split( "." ).sort(); - - // There *must* be a type, no attaching namespace-only handlers - if ( !type ) { - continue; - } - - // If event changes its type, use the special event handlers for the changed type - special = jQuery.event.special[ type ] || {}; - - // If selector defined, determine special event api type, otherwise given type - type = ( selector ? special.delegateType : special.bindType ) || type; - - // Update special based on newly reset type - special = jQuery.event.special[ type ] || {}; - - // handleObj is passed to all event handlers - handleObj = jQuery.extend({ - type: type, - origType: origType, - data: data, - handler: handler, - guid: handler.guid, - selector: selector, - needsContext: selector && jQuery.expr.match.needsContext.test( selector ), - namespace: namespaces.join(".") - }, handleObjIn ); - - // Init the event handler queue if we're the first - if ( !(handlers = events[ type ]) ) { - handlers = events[ type ] = []; - handlers.delegateCount = 0; - - // Only use addEventListener if the special events handler returns false - if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) { - if ( elem.addEventListener ) { - elem.addEventListener( type, eventHandle, false ); - } - } - } - - if ( special.add ) { - special.add.call( elem, handleObj ); - - if ( !handleObj.handler.guid ) { - handleObj.handler.guid = handler.guid; - } - } - - // Add to the element's handler list, delegates in front - if ( selector ) { - handlers.splice( handlers.delegateCount++, 0, handleObj ); - } else { - handlers.push( handleObj ); - } - - // Keep track of which events have ever been used, for event optimization - jQuery.event.global[ type ] = true; - } - - }, - - // Detach an event or set of events from an element - remove: function( elem, types, handler, selector, mappedTypes ) { - - var j, origCount, tmp, - events, t, handleObj, - special, handlers, type, namespaces, origType, - elemData = data_priv.hasData( elem ) && data_priv.get( elem ); - - if ( !elemData || !(events = elemData.events) ) { - return; - } - - // Once for each type.namespace in types; type may be omitted - types = ( types || "" ).match( rnotwhite ) || [ "" ]; - t = types.length; - while ( t-- ) { - tmp = rtypenamespace.exec( types[t] ) || []; - type = origType = tmp[1]; - namespaces = ( tmp[2] || "" ).split( "." ).sort(); - - // Unbind all events (on this namespace, if provided) for the element - if ( !type ) { - for ( type in events ) { - jQuery.event.remove( elem, type + types[ t ], handler, selector, true ); - } - continue; - } - - special = jQuery.event.special[ type ] || {}; - type = ( selector ? special.delegateType : special.bindType ) || type; - handlers = events[ type ] || []; - tmp = tmp[2] && new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" ); - - // Remove matching events - origCount = j = handlers.length; - while ( j-- ) { - handleObj = handlers[ j ]; - - if ( ( mappedTypes || origType === handleObj.origType ) && - ( !handler || handler.guid === handleObj.guid ) && - ( !tmp || tmp.test( handleObj.namespace ) ) && - ( !selector || selector === handleObj.selector || selector === "**" && handleObj.selector ) ) { - handlers.splice( j, 1 ); - - if ( handleObj.selector ) { - handlers.delegateCount--; - } - if ( special.remove ) { - special.remove.call( elem, handleObj ); - } - } - } - - // Remove generic event handler if we removed something and no more handlers exist - // (avoids potential for endless recursion during removal of special event handlers) - if ( origCount && !handlers.length ) { - if ( !special.teardown || special.teardown.call( elem, namespaces, elemData.handle ) === false ) { - jQuery.removeEvent( elem, type, elemData.handle ); - } - - delete events[ type ]; - } - } - - // Remove the expando if it's no longer used - if ( jQuery.isEmptyObject( events ) ) { - delete elemData.handle; - data_priv.remove( elem, "events" ); - } - }, - - trigger: function( event, data, elem, onlyHandlers ) { - - var i, cur, tmp, bubbleType, ontype, handle, special, - eventPath = [ elem || document ], - type = hasOwn.call( event, "type" ) ? event.type : event, - namespaces = hasOwn.call( event, "namespace" ) ? event.namespace.split(".") : []; - - cur = tmp = elem = elem || document; - - // Don't do events on text and comment nodes - if ( elem.nodeType === 3 || elem.nodeType === 8 ) { - return; - } - - // focus/blur morphs to focusin/out; ensure we're not firing them right now - if ( rfocusMorph.test( type + jQuery.event.triggered ) ) { - return; - } - - if ( type.indexOf(".") >= 0 ) { - // Namespaced trigger; create a regexp to match event type in handle() - namespaces = type.split("."); - type = namespaces.shift(); - namespaces.sort(); - } - ontype = type.indexOf(":") < 0 && "on" + type; - - // Caller can pass in a jQuery.Event object, Object, or just an event type string - event = event[ jQuery.expando ] ? - event : - new jQuery.Event( type, typeof event === "object" && event ); - - // Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true) - event.isTrigger = onlyHandlers ? 2 : 3; - event.namespace = namespaces.join("."); - event.namespace_re = event.namespace ? - new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" ) : - null; - - // Clean up the event in case it is being reused - event.result = undefined; - if ( !event.target ) { - event.target = elem; - } - - // Clone any incoming data and prepend the event, creating the handler arg list - data = data == null ? - [ event ] : - jQuery.makeArray( data, [ event ] ); - - // Allow special events to draw outside the lines - special = jQuery.event.special[ type ] || {}; - if ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) { - return; - } - - // Determine event propagation path in advance, per W3C events spec (#9951) - // Bubble up to document, then to window; watch for a global ownerDocument var (#9724) - if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) { - - bubbleType = special.delegateType || type; - if ( !rfocusMorph.test( bubbleType + type ) ) { - cur = cur.parentNode; - } - for ( ; cur; cur = cur.parentNode ) { - eventPath.push( cur ); - tmp = cur; - } - - // Only add window if we got to document (e.g., not plain obj or detached DOM) - if ( tmp === (elem.ownerDocument || document) ) { - eventPath.push( tmp.defaultView || tmp.parentWindow || window ); - } - } - - // Fire handlers on the event path - i = 0; - while ( (cur = eventPath[i++]) && !event.isPropagationStopped() ) { - - event.type = i > 1 ? - bubbleType : - special.bindType || type; - - // jQuery handler - handle = ( data_priv.get( cur, "events" ) || {} )[ event.type ] && data_priv.get( cur, "handle" ); - if ( handle ) { - handle.apply( cur, data ); - } - - // Native handler - handle = ontype && cur[ ontype ]; - if ( handle && handle.apply && jQuery.acceptData( cur ) ) { - event.result = handle.apply( cur, data ); - if ( event.result === false ) { - event.preventDefault(); - } - } - } - event.type = type; - - // If nobody prevented the default action, do it now - if ( !onlyHandlers && !event.isDefaultPrevented() ) { - - if ( (!special._default || special._default.apply( eventPath.pop(), data ) === false) && - jQuery.acceptData( elem ) ) { - - // Call a native DOM method on the target with the same name name as the event. - // Don't do default actions on window, that's where global variables be (#6170) - if ( ontype && jQuery.isFunction( elem[ type ] ) && !jQuery.isWindow( elem ) ) { - - // Don't re-trigger an onFOO event when we call its FOO() method - tmp = elem[ ontype ]; - - if ( tmp ) { - elem[ ontype ] = null; - } - - // Prevent re-triggering of the same event, since we already bubbled it above - jQuery.event.triggered = type; - elem[ type ](); - jQuery.event.triggered = undefined; - - if ( tmp ) { - elem[ ontype ] = tmp; - } - } - } - } - - return event.result; - }, - - dispatch: function( event ) { - - // Make a writable jQuery.Event from the native event object - event = jQuery.event.fix( event ); - - var i, j, ret, matched, handleObj, - handlerQueue = [], - args = slice.call( arguments ), - handlers = ( data_priv.get( this, "events" ) || {} )[ event.type ] || [], - special = jQuery.event.special[ event.type ] || {}; - - // Use the fix-ed jQuery.Event rather than the (read-only) native event - args[0] = event; - event.delegateTarget = this; - - // Call the preDispatch hook for the mapped type, and let it bail if desired - if ( special.preDispatch && special.preDispatch.call( this, event ) === false ) { - return; - } - - // Determine handlers - handlerQueue = jQuery.event.handlers.call( this, event, handlers ); - - // Run delegates first; they may want to stop propagation beneath us - i = 0; - while ( (matched = handlerQueue[ i++ ]) && !event.isPropagationStopped() ) { - event.currentTarget = matched.elem; - - j = 0; - while ( (handleObj = matched.handlers[ j++ ]) && !event.isImmediatePropagationStopped() ) { - - // Triggered event must either 1) have no namespace, or 2) have namespace(s) - // a subset or equal to those in the bound event (both can have no namespace). - if ( !event.namespace_re || event.namespace_re.test( handleObj.namespace ) ) { - - event.handleObj = handleObj; - event.data = handleObj.data; - - ret = ( (jQuery.event.special[ handleObj.origType ] || {}).handle || handleObj.handler ) - .apply( matched.elem, args ); - - if ( ret !== undefined ) { - if ( (event.result = ret) === false ) { - event.preventDefault(); - event.stopPropagation(); - } - } - } - } - } - - // Call the postDispatch hook for the mapped type - if ( special.postDispatch ) { - special.postDispatch.call( this, event ); - } - - return event.result; - }, - - handlers: function( event, handlers ) { - var i, matches, sel, handleObj, - handlerQueue = [], - delegateCount = handlers.delegateCount, - cur = event.target; - - // Find delegate handlers - // Black-hole SVG instance trees (#13180) - // Avoid non-left-click bubbling in Firefox (#3861) - if ( delegateCount && cur.nodeType && (!event.button || event.type !== "click") ) { - - for ( ; cur !== this; cur = cur.parentNode || this ) { - - // Don't process clicks on disabled elements (#6911, #8165, #11382, #11764) - if ( cur.disabled !== true || event.type !== "click" ) { - matches = []; - for ( i = 0; i < delegateCount; i++ ) { - handleObj = handlers[ i ]; - - // Don't conflict with Object.prototype properties (#13203) - sel = handleObj.selector + " "; - - if ( matches[ sel ] === undefined ) { - matches[ sel ] = handleObj.needsContext ? - jQuery( sel, this ).index( cur ) >= 0 : - jQuery.find( sel, this, null, [ cur ] ).length; - } - if ( matches[ sel ] ) { - matches.push( handleObj ); - } - } - if ( matches.length ) { - handlerQueue.push({ elem: cur, handlers: matches }); - } - } - } - } - - // Add the remaining (directly-bound) handlers - if ( delegateCount < handlers.length ) { - handlerQueue.push({ elem: this, handlers: handlers.slice( delegateCount ) }); - } - - return handlerQueue; - }, - - // Includes some event props shared by KeyEvent and MouseEvent - props: "altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "), - - fixHooks: {}, - - keyHooks: { - props: "char charCode key keyCode".split(" "), - filter: function( event, original ) { - - // Add which for key events - if ( event.which == null ) { - event.which = original.charCode != null ? original.charCode : original.keyCode; - } - - return event; - } - }, - - mouseHooks: { - props: "button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "), - filter: function( event, original ) { - var eventDoc, doc, body, - button = original.button; - - // Calculate pageX/Y if missing and clientX/Y available - if ( event.pageX == null && original.clientX != null ) { - eventDoc = event.target.ownerDocument || document; - doc = eventDoc.documentElement; - body = eventDoc.body; - - event.pageX = original.clientX + ( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) - ( doc && doc.clientLeft || body && body.clientLeft || 0 ); - event.pageY = original.clientY + ( doc && doc.scrollTop || body && body.scrollTop || 0 ) - ( doc && doc.clientTop || body && body.clientTop || 0 ); - } - - // Add which for click: 1 === left; 2 === middle; 3 === right - // Note: button is not normalized, so don't use it - if ( !event.which && button !== undefined ) { - event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) ); - } - - return event; - } - }, - - fix: function( event ) { - if ( event[ jQuery.expando ] ) { - return event; - } - - // Create a writable copy of the event object and normalize some properties - var i, prop, copy, - type = event.type, - originalEvent = event, - fixHook = this.fixHooks[ type ]; - - if ( !fixHook ) { - this.fixHooks[ type ] = fixHook = - rmouseEvent.test( type ) ? this.mouseHooks : - rkeyEvent.test( type ) ? this.keyHooks : - {}; - } - copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props; - - event = new jQuery.Event( originalEvent ); - - i = copy.length; - while ( i-- ) { - prop = copy[ i ]; - event[ prop ] = originalEvent[ prop ]; - } - - // Support: Cordova 2.5 (WebKit) (#13255) - // All events should have a target; Cordova deviceready doesn't - if ( !event.target ) { - event.target = document; - } - - // Support: Safari 6.0+, Chrome<28 - // Target should not be a text node (#504, #13143) - if ( event.target.nodeType === 3 ) { - event.target = event.target.parentNode; - } - - return fixHook.filter ? fixHook.filter( event, originalEvent ) : event; - }, - - special: { - load: { - // Prevent triggered image.load events from bubbling to window.load - noBubble: true - }, - focus: { - // Fire native event if possible so blur/focus sequence is correct - trigger: function() { - if ( this !== safeActiveElement() && this.focus ) { - this.focus(); - return false; - } - }, - delegateType: "focusin" - }, - blur: { - trigger: function() { - if ( this === safeActiveElement() && this.blur ) { - this.blur(); - return false; - } - }, - delegateType: "focusout" - }, - click: { - // For checkbox, fire native event so checked state will be right - trigger: function() { - if ( this.type === "checkbox" && this.click && jQuery.nodeName( this, "input" ) ) { - this.click(); - return false; - } - }, - - // For cross-browser consistency, don't fire native .click() on links - _default: function( event ) { - return jQuery.nodeName( event.target, "a" ); - } - }, - - beforeunload: { - postDispatch: function( event ) { - - // Support: Firefox 20+ - // Firefox doesn't alert if the returnValue field is not set. - if ( event.result !== undefined && event.originalEvent ) { - event.originalEvent.returnValue = event.result; - } - } - } - }, - - simulate: function( type, elem, event, bubble ) { - // Piggyback on a donor event to simulate a different one. - // Fake originalEvent to avoid donor's stopPropagation, but if the - // simulated event prevents default then we do the same on the donor. - var e = jQuery.extend( - new jQuery.Event(), - event, - { - type: type, - isSimulated: true, - originalEvent: {} - } - ); - if ( bubble ) { - jQuery.event.trigger( e, null, elem ); - } else { - jQuery.event.dispatch.call( elem, e ); - } - if ( e.isDefaultPrevented() ) { - event.preventDefault(); - } - } -}; - -jQuery.removeEvent = function( elem, type, handle ) { - if ( elem.removeEventListener ) { - elem.removeEventListener( type, handle, false ); - } -}; - -jQuery.Event = function( src, props ) { - // Allow instantiation without the 'new' keyword - if ( !(this instanceof jQuery.Event) ) { - return new jQuery.Event( src, props ); - } - - // Event object - if ( src && src.type ) { - this.originalEvent = src; - this.type = src.type; - - // Events bubbling up the document may have been marked as prevented - // by a handler lower down the tree; reflect the correct value. - this.isDefaultPrevented = src.defaultPrevented || - src.defaultPrevented === undefined && - // Support: Android<4.0 - src.returnValue === false ? - returnTrue : - returnFalse; - - // Event type - } else { - this.type = src; - } - - // Put explicitly provided properties onto the event object - if ( props ) { - jQuery.extend( this, props ); - } - - // Create a timestamp if incoming event doesn't have one - this.timeStamp = src && src.timeStamp || jQuery.now(); - - // Mark it as fixed - this[ jQuery.expando ] = true; -}; - -// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding -// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html -jQuery.Event.prototype = { - isDefaultPrevented: returnFalse, - isPropagationStopped: returnFalse, - isImmediatePropagationStopped: returnFalse, - - preventDefault: function() { - var e = this.originalEvent; - - this.isDefaultPrevented = returnTrue; - - if ( e && e.preventDefault ) { - e.preventDefault(); - } - }, - stopPropagation: function() { - var e = this.originalEvent; - - this.isPropagationStopped = returnTrue; - - if ( e && e.stopPropagation ) { - e.stopPropagation(); - } - }, - stopImmediatePropagation: function() { - var e = this.originalEvent; - - this.isImmediatePropagationStopped = returnTrue; - - if ( e && e.stopImmediatePropagation ) { - e.stopImmediatePropagation(); - } - - this.stopPropagation(); - } -}; - -// Create mouseenter/leave events using mouseover/out and event-time checks -// Support: Chrome 15+ -jQuery.each({ - mouseenter: "mouseover", - mouseleave: "mouseout", - pointerenter: "pointerover", - pointerleave: "pointerout" -}, function( orig, fix ) { - jQuery.event.special[ orig ] = { - delegateType: fix, - bindType: fix, - - handle: function( event ) { - var ret, - target = this, - related = event.relatedTarget, - handleObj = event.handleObj; - - // For mousenter/leave call the handler if related is outside the target. - // NB: No relatedTarget if the mouse left/entered the browser window - if ( !related || (related !== target && !jQuery.contains( target, related )) ) { - event.type = handleObj.origType; - ret = handleObj.handler.apply( this, arguments ); - event.type = fix; - } - return ret; - } - }; -}); - -// Support: Firefox, Chrome, Safari -// Create "bubbling" focus and blur events -if ( !support.focusinBubbles ) { - jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { - - // Attach a single capturing handler on the document while someone wants focusin/focusout - var handler = function( event ) { - jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ), true ); - }; - - jQuery.event.special[ fix ] = { - setup: function() { - var doc = this.ownerDocument || this, - attaches = data_priv.access( doc, fix ); - - if ( !attaches ) { - doc.addEventListener( orig, handler, true ); - } - data_priv.access( doc, fix, ( attaches || 0 ) + 1 ); - }, - teardown: function() { - var doc = this.ownerDocument || this, - attaches = data_priv.access( doc, fix ) - 1; - - if ( !attaches ) { - doc.removeEventListener( orig, handler, true ); - data_priv.remove( doc, fix ); - - } else { - data_priv.access( doc, fix, attaches ); - } - } - }; - }); -} - -jQuery.fn.extend({ - - on: function( types, selector, data, fn, /*INTERNAL*/ one ) { - var origFn, type; - - // Types can be a map of types/handlers - if ( typeof types === "object" ) { - // ( types-Object, selector, data ) - if ( typeof selector !== "string" ) { - // ( types-Object, data ) - data = data || selector; - selector = undefined; - } - for ( type in types ) { - this.on( type, selector, data, types[ type ], one ); - } - return this; - } - - if ( data == null && fn == null ) { - // ( types, fn ) - fn = selector; - data = selector = undefined; - } else if ( fn == null ) { - if ( typeof selector === "string" ) { - // ( types, selector, fn ) - fn = data; - data = undefined; - } else { - // ( types, data, fn ) - fn = data; - data = selector; - selector = undefined; - } - } - if ( fn === false ) { - fn = returnFalse; - } else if ( !fn ) { - return this; - } - - if ( one === 1 ) { - origFn = fn; - fn = function( event ) { - // Can use an empty set, since event contains the info - jQuery().off( event ); - return origFn.apply( this, arguments ); - }; - // Use same guid so caller can remove using origFn - fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ ); - } - return this.each( function() { - jQuery.event.add( this, types, fn, data, selector ); - }); - }, - one: function( types, selector, data, fn ) { - return this.on( types, selector, data, fn, 1 ); - }, - off: function( types, selector, fn ) { - var handleObj, type; - if ( types && types.preventDefault && types.handleObj ) { - // ( event ) dispatched jQuery.Event - handleObj = types.handleObj; - jQuery( types.delegateTarget ).off( - handleObj.namespace ? handleObj.origType + "." + handleObj.namespace : handleObj.origType, - handleObj.selector, - handleObj.handler - ); - return this; - } - if ( typeof types === "object" ) { - // ( types-object [, selector] ) - for ( type in types ) { - this.off( type, selector, types[ type ] ); - } - return this; - } - if ( selector === false || typeof selector === "function" ) { - // ( types [, fn] ) - fn = selector; - selector = undefined; - } - if ( fn === false ) { - fn = returnFalse; - } - return this.each(function() { - jQuery.event.remove( this, types, fn, selector ); - }); - }, - - trigger: function( type, data ) { - return this.each(function() { - jQuery.event.trigger( type, data, this ); - }); - }, - triggerHandler: function( type, data ) { - var elem = this[0]; - if ( elem ) { - return jQuery.event.trigger( type, data, elem, true ); - } - } -}); - - -var - rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi, - rtagName = /<([\w:]+)/, - rhtml = /<|&#?\w+;/, - rnoInnerhtml = /<(?:script|style|link)/i, - // checked="checked" or checked - rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i, - rscriptType = /^$|\/(?:java|ecma)script/i, - rscriptTypeMasked = /^true\/(.*)/, - rcleanScript = /^\s*\s*$/g, - - // We have to close these tags to support XHTML (#13200) - wrapMap = { - - // Support: IE9 - option: [ 1, "" ], - - thead: [ 1, "", "
" ], - col: [ 2, "", "
" ], - tr: [ 2, "", "
" ], - td: [ 3, "", "
" ], - - _default: [ 0, "", "" ] - }; - -// Support: IE9 -wrapMap.optgroup = wrapMap.option; - -wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead; -wrapMap.th = wrapMap.td; - -// Support: 1.x compatibility -// Manipulating tables requires a tbody -function manipulationTarget( elem, content ) { - return jQuery.nodeName( elem, "table" ) && - jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ? - - elem.getElementsByTagName("tbody")[0] || - elem.appendChild( elem.ownerDocument.createElement("tbody") ) : - elem; -} - -// Replace/restore the type attribute of script elements for safe DOM manipulation -function disableScript( elem ) { - elem.type = (elem.getAttribute("type") !== null) + "/" + elem.type; - return elem; -} -function restoreScript( elem ) { - var match = rscriptTypeMasked.exec( elem.type ); - - if ( match ) { - elem.type = match[ 1 ]; - } else { - elem.removeAttribute("type"); - } - - return elem; -} - -// Mark scripts as having already been evaluated -function setGlobalEval( elems, refElements ) { - var i = 0, - l = elems.length; - - for ( ; i < l; i++ ) { - data_priv.set( - elems[ i ], "globalEval", !refElements || data_priv.get( refElements[ i ], "globalEval" ) - ); - } -} - -function cloneCopyEvent( src, dest ) { - var i, l, type, pdataOld, pdataCur, udataOld, udataCur, events; - - if ( dest.nodeType !== 1 ) { - return; - } - - // 1. Copy private data: events, handlers, etc. - if ( data_priv.hasData( src ) ) { - pdataOld = data_priv.access( src ); - pdataCur = data_priv.set( dest, pdataOld ); - events = pdataOld.events; - - if ( events ) { - delete pdataCur.handle; - pdataCur.events = {}; - - for ( type in events ) { - for ( i = 0, l = events[ type ].length; i < l; i++ ) { - jQuery.event.add( dest, type, events[ type ][ i ] ); - } - } - } - } - - // 2. Copy user data - if ( data_user.hasData( src ) ) { - udataOld = data_user.access( src ); - udataCur = jQuery.extend( {}, udataOld ); - - data_user.set( dest, udataCur ); - } -} - -function getAll( context, tag ) { - var ret = context.getElementsByTagName ? context.getElementsByTagName( tag || "*" ) : - context.querySelectorAll ? context.querySelectorAll( tag || "*" ) : - []; - - return tag === undefined || tag && jQuery.nodeName( context, tag ) ? - jQuery.merge( [ context ], ret ) : - ret; -} - -// Fix IE bugs, see support tests -function fixInput( src, dest ) { - var nodeName = dest.nodeName.toLowerCase(); - - // Fails to persist the checked state of a cloned checkbox or radio button. - if ( nodeName === "input" && rcheckableType.test( src.type ) ) { - dest.checked = src.checked; - - // Fails to return the selected option to the default selected state when cloning options - } else if ( nodeName === "input" || nodeName === "textarea" ) { - dest.defaultValue = src.defaultValue; - } -} - -jQuery.extend({ - clone: function( elem, dataAndEvents, deepDataAndEvents ) { - var i, l, srcElements, destElements, - clone = elem.cloneNode( true ), - inPage = jQuery.contains( elem.ownerDocument, elem ); - - // Fix IE cloning issues - if ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) && - !jQuery.isXMLDoc( elem ) ) { - - // We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2 - destElements = getAll( clone ); - srcElements = getAll( elem ); - - for ( i = 0, l = srcElements.length; i < l; i++ ) { - fixInput( srcElements[ i ], destElements[ i ] ); - } - } - - // Copy the events from the original to the clone - if ( dataAndEvents ) { - if ( deepDataAndEvents ) { - srcElements = srcElements || getAll( elem ); - destElements = destElements || getAll( clone ); - - for ( i = 0, l = srcElements.length; i < l; i++ ) { - cloneCopyEvent( srcElements[ i ], destElements[ i ] ); - } - } else { - cloneCopyEvent( elem, clone ); - } - } - - // Preserve script evaluation history - destElements = getAll( clone, "script" ); - if ( destElements.length > 0 ) { - setGlobalEval( destElements, !inPage && getAll( elem, "script" ) ); - } - - // Return the cloned set - return clone; - }, - - buildFragment: function( elems, context, scripts, selection ) { - var elem, tmp, tag, wrap, contains, j, - fragment = context.createDocumentFragment(), - nodes = [], - i = 0, - l = elems.length; - - for ( ; i < l; i++ ) { - elem = elems[ i ]; - - if ( elem || elem === 0 ) { - - // Add nodes directly - if ( jQuery.type( elem ) === "object" ) { - // Support: QtWebKit, PhantomJS - // push.apply(_, arraylike) throws on ancient WebKit - jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem ); - - // Convert non-html into a text node - } else if ( !rhtml.test( elem ) ) { - nodes.push( context.createTextNode( elem ) ); - - // Convert html into DOM nodes - } else { - tmp = tmp || fragment.appendChild( context.createElement("div") ); - - // Deserialize a standard representation - tag = ( rtagName.exec( elem ) || [ "", "" ] )[ 1 ].toLowerCase(); - wrap = wrapMap[ tag ] || wrapMap._default; - tmp.innerHTML = wrap[ 1 ] + elem.replace( rxhtmlTag, "<$1>" ) + wrap[ 2 ]; - - // Descend through wrappers to the right content - j = wrap[ 0 ]; - while ( j-- ) { - tmp = tmp.lastChild; - } - - // Support: QtWebKit, PhantomJS - // push.apply(_, arraylike) throws on ancient WebKit - jQuery.merge( nodes, tmp.childNodes ); - - // Remember the top-level container - tmp = fragment.firstChild; - - // Ensure the created nodes are orphaned (#12392) - tmp.textContent = ""; - } - } - } - - // Remove wrapper from fragment - fragment.textContent = ""; - - i = 0; - while ( (elem = nodes[ i++ ]) ) { - - // #4087 - If origin and destination elements are the same, and this is - // that element, do not do anything - if ( selection && jQuery.inArray( elem, selection ) !== -1 ) { - continue; - } - - contains = jQuery.contains( elem.ownerDocument, elem ); - - // Append to fragment - tmp = getAll( fragment.appendChild( elem ), "script" ); - - // Preserve script evaluation history - if ( contains ) { - setGlobalEval( tmp ); - } - - // Capture executables - if ( scripts ) { - j = 0; - while ( (elem = tmp[ j++ ]) ) { - if ( rscriptType.test( elem.type || "" ) ) { - scripts.push( elem ); - } - } - } - } - - return fragment; - }, - - cleanData: function( elems ) { - var data, elem, type, key, - special = jQuery.event.special, - i = 0; - - for ( ; (elem = elems[ i ]) !== undefined; i++ ) { - if ( jQuery.acceptData( elem ) ) { - key = elem[ data_priv.expando ]; - - if ( key && (data = data_priv.cache[ key ]) ) { - if ( data.events ) { - for ( type in data.events ) { - if ( special[ type ] ) { - jQuery.event.remove( elem, type ); - - // This is a shortcut to avoid jQuery.event.remove's overhead - } else { - jQuery.removeEvent( elem, type, data.handle ); - } - } - } - if ( data_priv.cache[ key ] ) { - // Discard any remaining `private` data - delete data_priv.cache[ key ]; - } - } - } - // Discard any remaining `user` data - delete data_user.cache[ elem[ data_user.expando ] ]; - } - } -}); - -jQuery.fn.extend({ - text: function( value ) { - return access( this, function( value ) { - return value === undefined ? - jQuery.text( this ) : - this.empty().each(function() { - if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) { - this.textContent = value; - } - }); - }, null, value, arguments.length ); - }, - - append: function() { - return this.domManip( arguments, function( elem ) { - if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) { - var target = manipulationTarget( this, elem ); - target.appendChild( elem ); - } - }); - }, - - prepend: function() { - return this.domManip( arguments, function( elem ) { - if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) { - var target = manipulationTarget( this, elem ); - target.insertBefore( elem, target.firstChild ); - } - }); - }, - - before: function() { - return this.domManip( arguments, function( elem ) { - if ( this.parentNode ) { - this.parentNode.insertBefore( elem, this ); - } - }); - }, - - after: function() { - return this.domManip( arguments, function( elem ) { - if ( this.parentNode ) { - this.parentNode.insertBefore( elem, this.nextSibling ); - } - }); - }, - - remove: function( selector, keepData /* Internal Use Only */ ) { - var elem, - elems = selector ? jQuery.filter( selector, this ) : this, - i = 0; - - for ( ; (elem = elems[i]) != null; i++ ) { - if ( !keepData && elem.nodeType === 1 ) { - jQuery.cleanData( getAll( elem ) ); - } - - if ( elem.parentNode ) { - if ( keepData && jQuery.contains( elem.ownerDocument, elem ) ) { - setGlobalEval( getAll( elem, "script" ) ); - } - elem.parentNode.removeChild( elem ); - } - } - - return this; - }, - - empty: function() { - var elem, - i = 0; - - for ( ; (elem = this[i]) != null; i++ ) { - if ( elem.nodeType === 1 ) { - - // Prevent memory leaks - jQuery.cleanData( getAll( elem, false ) ); - - // Remove any remaining nodes - elem.textContent = ""; - } - } - - return this; - }, - - clone: function( dataAndEvents, deepDataAndEvents ) { - dataAndEvents = dataAndEvents == null ? false : dataAndEvents; - deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents; - - return this.map(function() { - return jQuery.clone( this, dataAndEvents, deepDataAndEvents ); - }); - }, - - html: function( value ) { - return access( this, function( value ) { - var elem = this[ 0 ] || {}, - i = 0, - l = this.length; - - if ( value === undefined && elem.nodeType === 1 ) { - return elem.innerHTML; - } - - // See if we can take a shortcut and just use innerHTML - if ( typeof value === "string" && !rnoInnerhtml.test( value ) && - !wrapMap[ ( rtagName.exec( value ) || [ "", "" ] )[ 1 ].toLowerCase() ] ) { - - value = value.replace( rxhtmlTag, "<$1>" ); - - try { - for ( ; i < l; i++ ) { - elem = this[ i ] || {}; - - // Remove element nodes and prevent memory leaks - if ( elem.nodeType === 1 ) { - jQuery.cleanData( getAll( elem, false ) ); - elem.innerHTML = value; - } - } - - elem = 0; - - // If using innerHTML throws an exception, use the fallback method - } catch( e ) {} - } - - if ( elem ) { - this.empty().append( value ); - } - }, null, value, arguments.length ); - }, - - replaceWith: function() { - var arg = arguments[ 0 ]; - - // Make the changes, replacing each context element with the new content - this.domManip( arguments, function( elem ) { - arg = this.parentNode; - - jQuery.cleanData( getAll( this ) ); - - if ( arg ) { - arg.replaceChild( elem, this ); - } - }); - - // Force removal if there was no new content (e.g., from empty arguments) - return arg && (arg.length || arg.nodeType) ? this : this.remove(); - }, - - detach: function( selector ) { - return this.remove( selector, true ); - }, - - domManip: function( args, callback ) { - - // Flatten any nested arrays - args = concat.apply( [], args ); - - var fragment, first, scripts, hasScripts, node, doc, - i = 0, - l = this.length, - set = this, - iNoClone = l - 1, - value = args[ 0 ], - isFunction = jQuery.isFunction( value ); - - // We can't cloneNode fragments that contain checked, in WebKit - if ( isFunction || - ( l > 1 && typeof value === "string" && - !support.checkClone && rchecked.test( value ) ) ) { - return this.each(function( index ) { - var self = set.eq( index ); - if ( isFunction ) { - args[ 0 ] = value.call( this, index, self.html() ); - } - self.domManip( args, callback ); - }); - } - - if ( l ) { - fragment = jQuery.buildFragment( args, this[ 0 ].ownerDocument, false, this ); - first = fragment.firstChild; - - if ( fragment.childNodes.length === 1 ) { - fragment = first; - } - - if ( first ) { - scripts = jQuery.map( getAll( fragment, "script" ), disableScript ); - hasScripts = scripts.length; - - // Use the original fragment for the last item instead of the first because it can end up - // being emptied incorrectly in certain situations (#8070). - for ( ; i < l; i++ ) { - node = fragment; - - if ( i !== iNoClone ) { - node = jQuery.clone( node, true, true ); - - // Keep references to cloned scripts for later restoration - if ( hasScripts ) { - // Support: QtWebKit - // jQuery.merge because push.apply(_, arraylike) throws - jQuery.merge( scripts, getAll( node, "script" ) ); - } - } - - callback.call( this[ i ], node, i ); - } - - if ( hasScripts ) { - doc = scripts[ scripts.length - 1 ].ownerDocument; - - // Reenable scripts - jQuery.map( scripts, restoreScript ); - - // Evaluate executable scripts on first document insertion - for ( i = 0; i < hasScripts; i++ ) { - node = scripts[ i ]; - if ( rscriptType.test( node.type || "" ) && - !data_priv.access( node, "globalEval" ) && jQuery.contains( doc, node ) ) { - - if ( node.src ) { - // Optional AJAX dependency, but won't run scripts if not present - if ( jQuery._evalUrl ) { - jQuery._evalUrl( node.src ); - } - } else { - jQuery.globalEval( node.textContent.replace( rcleanScript, "" ) ); - } - } - } - } - } - } - - return this; - } -}); - -jQuery.each({ - appendTo: "append", - prependTo: "prepend", - insertBefore: "before", - insertAfter: "after", - replaceAll: "replaceWith" -}, function( name, original ) { - jQuery.fn[ name ] = function( selector ) { - var elems, - ret = [], - insert = jQuery( selector ), - last = insert.length - 1, - i = 0; - - for ( ; i <= last; i++ ) { - elems = i === last ? this : this.clone( true ); - jQuery( insert[ i ] )[ original ]( elems ); - - // Support: QtWebKit - // .get() because push.apply(_, arraylike) throws - push.apply( ret, elems.get() ); - } - - return this.pushStack( ret ); - }; -}); - - -var iframe, - elemdisplay = {}; - -/** - * Retrieve the actual display of a element - * @param {String} name nodeName of the element - * @param {Object} doc Document object - */ -// Called only from within defaultDisplay -function actualDisplay( name, doc ) { - var style, - elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ), - - // getDefaultComputedStyle might be reliably used only on attached element - display = window.getDefaultComputedStyle && ( style = window.getDefaultComputedStyle( elem[ 0 ] ) ) ? - - // Use of this method is a temporary fix (more like optimization) until something better comes along, - // since it was removed from specification and supported only in FF - style.display : jQuery.css( elem[ 0 ], "display" ); - - // We don't have any data stored on the element, - // so use "detach" method as fast way to get rid of the element - elem.detach(); - - return display; -} - -/** - * Try to determine the default display value of an element - * @param {String} nodeName - */ -function defaultDisplay( nodeName ) { - var doc = document, - display = elemdisplay[ nodeName ]; - - if ( !display ) { - display = actualDisplay( nodeName, doc ); - - // If the simple way fails, read from inside an iframe - if ( display === "none" || !display ) { - - // Use the already-created iframe if possible - iframe = (iframe || jQuery( "