Skip to content

Commit

Permalink
publish to pages workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
MauriceConrad committed Apr 14, 2024
1 parent c99923c commit f4811a0
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 29 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,28 @@ jobs:
run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

deploy-cloudflare:
runs-on: ubuntu-latest
needs: publish-npm
env:
CLOUDFLARE_PROJECT_NAME: zoompinch

steps:
- uses: actions/checkout@v2
- name: Install latest zoompinch
run: npm install zoompinch@latest
working-directory: playground
- name: test installed version
run: cat package.json | grep -e '"zoompinch":'
working-directory: playground
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{env.CLOUDFLARE_PROJECT_NAME}}
directory: dist
branch: main
workingDirectory: playground
wranglerVersion: '3'
5 changes: 2 additions & 3 deletions playground/src/components/Playground.vue
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,7 @@ const zoompinchRef = ref<InstanceType<typeof Zoompinch>>();
const offset = reactive({ top: 10, right: 10, bottom: 10, left: 10 });
(window as any).offset = offset;
//const transform = ref({ x: 0, y: 0, scale: 1, rotate: 0 });
const transform = ref({ x: 100, y: 0, scale: 0.1, rotate: 180 }); // Flicker bug reproducable: 100,0,0.1,180
const transform = ref({ x: 0, y: 0, scale: 1, rotate: 0 });
(window as any).transform = transform;
const updateTransform = (newTransform: Partial<typeof transform.value>) => {
transform.value = { ...transform.value, ...newTransform };
Expand Down Expand Up @@ -207,7 +206,7 @@ function handleClickOnLayer(event: MouseEvent) {
overflow: hidden;
flex-direction: row;
gap: 20px;
gap: 10px;
@media screen and (max-width: 700px) {
flex-direction: column;
}
Expand Down
25 changes: 0 additions & 25 deletions tests/.gitignore

This file was deleted.

2 changes: 1 addition & 1 deletion zoompinch-vue/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "zoompinch",
"private": false,
"version": "0.0.13",
"version": "0.0.14",
"type": "module",
"files": [
"package.json",
Expand Down

0 comments on commit f4811a0

Please sign in to comment.