Files
webstudio/.github/workflows/check-submodules.yml
Ivan Starkov 68a28b4eee experimental: Proof of concept of the Animation component using ScrollTimeline (#4797)
## Description

ref #2645

Proof of Concept for the Animation Component Using ScrollTimeline

For FF and Safari `scroll-timeline-polyfill` is used.

SSR Support https://animate.development.webstudio.is/playground
Storybook Part 1. 

https://6382151c8b47d4399fb9fc69-limlyrmprp.chromatic.com/?path=/story/sdk-components-animation-scroll-animations--in-out

Next steps:

- Add stories with additional examples i.e. closest usage, images etc.
https://scroll-driven-animations.style/
- Add support to view animations
- Add view animations examples
- Add enter/leave actions and animations support
- Builder UI
- Add lottie, rive etc compatibility (should work through
context.getAnimations()[0].effect.getComputedTiming().progress)

## Steps for reproduction

1. click button
2. expect xyz

## Code Review

- [ ] hi @kof, I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
0000)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio/blob/main/apps/builder/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env` file
2025-02-01 14:57:36 +03:00

68 lines
2.0 KiB
YAML

name: Check submodules
on:
pull_request:
# cancel in-progress runs on new commits to same PR (gitub.event.number)
concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.sha }}
cancel-in-progress: true
permissions:
contents: read # to fetch code (actions/checkout)
jobs:
checks:
timeout-minutes: 20
environment:
name: development
env:
DATABASE_URL: postgres://
AUTH_SECRET: test
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
- uses: ./.github/actions/submodules-checkout
with:
submodules-ssh-key: ${{ secrets.PRIVATE_GITHUB_DEPLOY_TOKEN }}
- name: Check if any submodule branch matches github.ref_name
run: |
echo "C ${{ github.workflow }}-${{ github.event.number || github.sha }}"
# Get the current branch or tag name
REF_NAME="${{ github.event.pull_request.head.ref || github.ref_name }}"
echo "Branch is:" $REF_NAME
# List all submodule paths
SUBMODULES=$(git submodule status | awk '{print $2}')
# Check each submodule's branch
for SUBMODULE in $SUBMODULES; do
echo "Checking submodule: $SUBMODULE"
(
cd "$SUBMODULE"
# Get the current branch of the submodule
SUBMODULE_BRANCH=$(git rev-parse --abbrev-ref HEAD)
echo "Submodule branch: $SUBMODULE_BRANCH"
# Compare the submodule branch to the ref_name
if [ "$SUBMODULE_BRANCH" = "$REF_NAME" ]; then
echo "::error::Submodule '$SUBMODULE' is on branch '$SUBMODULE_BRANCH', which matches the current ref '$REF_NAME'."
exit 1
fi
)
if [ $? -ne 0 ]; then
exit 1 # Fail the workflow if any submodule branch matches
fi
done
echo "No submodule is on the same branch as the current ref '$REF_NAME'."