forked from LinusBorg/vue-simple-portal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
46 changed files
with
5,702 additions
and
903 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Javascript Node CircleCI 2.0 configuration file | ||
# | ||
# Check https://circleci.com/docs/2.0/language-javascript/ for more details | ||
# | ||
version: 2 | ||
jobs: | ||
build: | ||
docker: | ||
# specify the version you desire here | ||
- image: cypress/base:8 | ||
|
||
# Specify service dependencies here if necessary | ||
# CircleCI maintains a library of pre-built images | ||
# documented at https://circleci.com/docs/2.0/circleci-images/ | ||
# - image: circleci/mongo:3.4.4 | ||
|
||
working_directory: ~/repo | ||
|
||
steps: | ||
- checkout | ||
|
||
# Download and cache dependencies | ||
- restore_cache: | ||
keys: | ||
- v1-dependencies-{{.Branch}}-{{ checksum "package.json" }} | ||
- v1-dependencies-{{.Branch}} | ||
# fallback to using the latest cache if no exact match is found | ||
- v1-dependencies- | ||
|
||
- run: yarn install | ||
|
||
- save_cache: | ||
paths: | ||
- ~/cache | ||
key: v1-dependencies-{{.Branch}}-{{ checksum "package.json" }} | ||
|
||
# run tests! | ||
- run: yarn build | ||
- run: yarn test:unit --coverage | ||
- run: yarn test:e2e-ci | ||
- store_artifacts: | ||
path: /artifacts/e2e/video | ||
- store_test_results: | ||
path: ./coverage | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
package/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
.DS_Store | ||
node_modules | ||
/package/dist | ||
TODO.md | ||
|
||
/coverage | ||
/tests/e2e/videos/ | ||
/tests/e2e/screenshots/ | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Copyright 2019 Thorsten Lünborg | ||
|
||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
|
||
http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
package/README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
const { version } = require('./package/package.json') | ||
/** @type {import('bili').Config} */ | ||
module.exports = { | ||
banner: ` | ||
/** | ||
* vue-simple-portal | ||
* version: ${version}, | ||
* (c) Thorsten Lünborg, ${new Date().getFullYear()} | ||
* LICENCE: Apache-2.0 | ||
* http://github.com/linusborg/vue-simple-portal | ||
*/`, | ||
plugins: { | ||
commonjs: true, | ||
vue: true, | ||
}, | ||
// bundleNodeModules: true, | ||
externals: ['nanoid'], | ||
globals: { | ||
vue: 'Vue', | ||
}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<template> | ||
<div> | ||
<h1>Basic Use Case</h1> | ||
<portal> | ||
<Test /> | ||
</portal> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Test from './TestComponent' | ||
export default { | ||
name: 'Base', | ||
components: { | ||
Test, | ||
}, | ||
} | ||
</script> | ||
|
||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<template> | ||
<div> | ||
<h1>Basic Use Case</h1> | ||
<portal selector="#custom-target"> | ||
<Test /> | ||
</portal> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Test from './TestComponent' | ||
export default { | ||
name: 'Base', | ||
components: { | ||
Test, | ||
}, | ||
} | ||
</script> | ||
|
||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<template> | ||
<div> | ||
<h1 dataTest="disable-h1">Disabled State</h1> | ||
<portal disabled> | ||
<Test /> | ||
</portal> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Test from './TestComponent' | ||
export default { | ||
name: 'Base', | ||
components: { | ||
Test, | ||
}, | ||
} | ||
</script> | ||
|
||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<template> | ||
<div> | ||
<h1>Multiple Portals</h1> | ||
<portal> | ||
<Test /> | ||
</portal> | ||
<br /> | ||
<portal prepend> | ||
<p data-test="multiple-p">Test String from a second portal</p> | ||
</portal> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Test from './TestComponent' | ||
export default { | ||
name: 'Base', | ||
components: { | ||
Test, | ||
}, | ||
} | ||
</script> | ||
|
||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<template> | ||
<div> | ||
<h1>Transitions</h1> | ||
<button id="toggle-button" @click="toggle = !toggle">Toggle</button> | ||
<portal> | ||
<transition name="fade"> | ||
<Test v-if="toggle" /> | ||
</transition> | ||
</portal> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Test from './TestComponent' | ||
export default { | ||
name: 'Base', | ||
components: { | ||
Test, | ||
}, | ||
data: () => ({ | ||
toggle: false, | ||
}), | ||
} | ||
</script> | ||
|
||
<style> | ||
.fade-enter-active, | ||
.fade-leave-active { | ||
transition: opacity 0.4s; | ||
} | ||
.fade-enter, .fade-leave-to /* .fade-leave-active below version 2.1.8 */ { | ||
opacity: 0; | ||
} | ||
</style> |
Oops, something went wrong.