From 649eb847bee844501ae336e8bcfd211b983c1861 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Mon, 19 Feb 2024 23:39:09 +0100 Subject: [PATCH 01/12] feat: challenge 45 Simple Animations --- README.md | 2 +- apps/angular/simple-animations/.eslintrc.json | 36 ++++++++ apps/angular/simple-animations/README.md | 13 +++ apps/angular/simple-animations/jest.config.ts | 22 +++++ apps/angular/simple-animations/project.json | 80 ++++++++++++++++++ .../src/app/app.component.spec.ts | 8 ++ .../src/app/app.component.ts | 78 +++++++++++++++++ .../simple-animations/src/app/app.config.ts | 5 ++ .../simple-animations/src/assets/.gitkeep | 0 .../angular/simple-animations/src/favicon.ico | Bin 0 -> 15086 bytes apps/angular/simple-animations/src/index.html | 13 +++ apps/angular/simple-animations/src/main.ts | 7 ++ .../angular/simple-animations/src/styles.scss | 5 ++ .../simple-animations/src/test-setup.ts | 2 + .../simple-animations/tailwind.config.js | 14 +++ .../simple-animations/tsconfig.app.json | 10 +++ .../simple-animations/tsconfig.editor.json | 7 ++ apps/angular/simple-animations/tsconfig.json | 33 ++++++++ .../simple-animations/tsconfig.spec.json | 15 ++++ challenge-number.json | 4 +- .../challenges/angular/44-view-transition.md | 1 - .../angular/45-simple-animations.md | 38 +++++++++ docs/src/content/docs/es/index.mdx | 13 +-- docs/src/content/docs/fr/index.mdx | 10 +-- docs/src/content/docs/index.mdx | 9 +- docs/src/content/docs/pt/index.mdx | 15 ++-- docs/src/content/docs/ru/index.mdx | 33 ++++---- 27 files changed, 431 insertions(+), 42 deletions(-) create mode 100644 apps/angular/simple-animations/.eslintrc.json create mode 100644 apps/angular/simple-animations/README.md create mode 100644 apps/angular/simple-animations/jest.config.ts create mode 100644 apps/angular/simple-animations/project.json create mode 100644 apps/angular/simple-animations/src/app/app.component.spec.ts create mode 100644 apps/angular/simple-animations/src/app/app.component.ts create mode 100644 apps/angular/simple-animations/src/app/app.config.ts create mode 100644 apps/angular/simple-animations/src/assets/.gitkeep create mode 100644 apps/angular/simple-animations/src/favicon.ico create mode 100644 apps/angular/simple-animations/src/index.html create mode 100644 apps/angular/simple-animations/src/main.ts create mode 100644 apps/angular/simple-animations/src/styles.scss create mode 100644 apps/angular/simple-animations/src/test-setup.ts create mode 100644 apps/angular/simple-animations/tailwind.config.js create mode 100644 apps/angular/simple-animations/tsconfig.app.json create mode 100644 apps/angular/simple-animations/tsconfig.editor.json create mode 100644 apps/angular/simple-animations/tsconfig.json create mode 100644 apps/angular/simple-animations/tsconfig.spec.json create mode 100644 docs/src/content/docs/challenges/angular/45-simple-animations.md diff --git a/README.md b/README.md index 1e43bdf..de88144 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ If you would like to propose a challenge, this project is open source, so feel f ## Challenges -Check [all 44 challenges](https://angular-challenges.vercel.app/) +Check [all 45 challenges](https://angular-challenges.vercel.app/) ## Contributors ✨ diff --git a/apps/angular/simple-animations/.eslintrc.json b/apps/angular/simple-animations/.eslintrc.json new file mode 100644 index 0000000..8ebcbfd --- /dev/null +++ b/apps/angular/simple-animations/.eslintrc.json @@ -0,0 +1,36 @@ +{ + "extends": ["../../../.eslintrc.json"], + "ignorePatterns": ["!**/*"], + "overrides": [ + { + "files": ["*.ts"], + "extends": [ + "plugin:@nx/angular", + "plugin:@angular-eslint/template/process-inline-templates" + ], + "rules": { + "@angular-eslint/directive-selector": [ + "error", + { + "type": "attribute", + "prefix": "app", + "style": "camelCase" + } + ], + "@angular-eslint/component-selector": [ + "error", + { + "type": "element", + "prefix": "app", + "style": "kebab-case" + } + ] + } + }, + { + "files": ["*.html"], + "extends": ["plugin:@nx/angular-template"], + "rules": {} + } + ] +} diff --git a/apps/angular/simple-animations/README.md b/apps/angular/simple-animations/README.md new file mode 100644 index 0000000..f151448 --- /dev/null +++ b/apps/angular/simple-animations/README.md @@ -0,0 +1,13 @@ +# Simple Animations + +> author: thomas-laforge + +### Run Application + +```bash +npx nx serve angular-simple-animations +``` + +### Documentation and Instruction + +Challenge documentation is [here](https://angular-challenges.vercel.app/challenges/angular/45-simple-animations/). diff --git a/apps/angular/simple-animations/jest.config.ts b/apps/angular/simple-animations/jest.config.ts new file mode 100644 index 0000000..8f5d36c --- /dev/null +++ b/apps/angular/simple-animations/jest.config.ts @@ -0,0 +1,22 @@ +/* eslint-disable */ +export default { + displayName: 'angular-simple-animations', + preset: '../../../jest.preset.js', + setupFilesAfterEnv: ['/src/test-setup.ts'], + coverageDirectory: '../../../coverage/apps/angular/simple-animations', + transform: { + '^.+\\.(ts|mjs|js|html)$': [ + 'jest-preset-angular', + { + tsconfig: '/tsconfig.spec.json', + stringifyContentPathRegex: '\\.(html|svg)$', + }, + ], + }, + transformIgnorePatterns: ['node_modules/(?!.*\\.mjs$)'], + snapshotSerializers: [ + 'jest-preset-angular/build/serializers/no-ng-attributes', + 'jest-preset-angular/build/serializers/ng-snapshot', + 'jest-preset-angular/build/serializers/html-comment', + ], +}; diff --git a/apps/angular/simple-animations/project.json b/apps/angular/simple-animations/project.json new file mode 100644 index 0000000..4ba302d --- /dev/null +++ b/apps/angular/simple-animations/project.json @@ -0,0 +1,80 @@ +{ + "name": "angular-simple-animations", + "$schema": "../../../node_modules/nx/schemas/project-schema.json", + "projectType": "application", + "prefix": "app", + "sourceRoot": "apps/angular/simple-animations/src", + "tags": [], + "targets": { + "build": { + "executor": "@angular-devkit/build-angular:application", + "outputs": ["{options.outputPath}"], + "options": { + "outputPath": "dist/apps/angular/simple-animations", + "index": "apps/angular/simple-animations/src/index.html", + "browser": "apps/angular/simple-animations/src/main.ts", + "polyfills": ["zone.js"], + "tsConfig": "apps/angular/simple-animations/tsconfig.app.json", + "inlineStyleLanguage": "scss", + "assets": [ + "apps/angular/simple-animations/src/favicon.ico", + "apps/angular/simple-animations/src/assets" + ], + "styles": ["apps/angular/simple-animations/src/styles.scss"], + "scripts": [] + }, + "configurations": { + "production": { + "budgets": [ + { + "type": "initial", + "maximumWarning": "500kb", + "maximumError": "1mb" + }, + { + "type": "anyComponentStyle", + "maximumWarning": "2kb", + "maximumError": "4kb" + } + ], + "outputHashing": "all" + }, + "development": { + "optimization": false, + "extractLicenses": false, + "sourceMap": true + } + }, + "defaultConfiguration": "production" + }, + "serve": { + "executor": "@angular-devkit/build-angular:dev-server", + "configurations": { + "production": { + "buildTarget": "angular-simple-animations:build:production" + }, + "development": { + "buildTarget": "angular-simple-animations:build:development" + } + }, + "defaultConfiguration": "development" + }, + "extract-i18n": { + "executor": "@angular-devkit/build-angular:extract-i18n", + "options": { + "buildTarget": "angular-simple-animations:build" + } + }, + "lint": { + "executor": "@nx/eslint:lint", + "outputs": ["{options.outputFile}"] + }, + "test": { + "executor": "@nx/jest:jest", + "outputs": ["{workspaceRoot}/coverage/{projectRoot}"], + "options": { + "jestConfig": "apps/angular/simple-animations/jest.config.ts" + } + } + } +} diff --git a/apps/angular/simple-animations/src/app/app.component.spec.ts b/apps/angular/simple-animations/src/app/app.component.spec.ts new file mode 100644 index 0000000..3905d62 --- /dev/null +++ b/apps/angular/simple-animations/src/app/app.component.spec.ts @@ -0,0 +1,8 @@ +import { render } from '@testing-library/angular'; +import { AppComponent } from './app.component'; + +describe('AppComponent', () => { + test('...', async () => { + await render(AppComponent); + }); +}); diff --git a/apps/angular/simple-animations/src/app/app.component.ts b/apps/angular/simple-animations/src/app/app.component.ts new file mode 100644 index 0000000..c194f4a --- /dev/null +++ b/apps/angular/simple-animations/src/app/app.component.ts @@ -0,0 +1,78 @@ +import { Component } from '@angular/core'; + +@Component({ + standalone: true, + imports: [], + selector: 'app-root', + template: ` +
+
+
+

2008

+

+ Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae + mollitia sequi accusantium, distinctio similique laudantium eveniet + quidem sit placeat possimus tempore dolorum inventore corporis atque + quae ad, nobis explicabo delectus. +

+
+ +
+

2010

+

+ Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae + mollitia sequi accusantium, distinctio similique laudantium eveniet + quidem sit placeat possimus tempore dolorum inventore corporis atque + quae ad, nobis explicabo delectus. +

+
+ +
+

2012

+

+ Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae + mollitia sequi accusantium, distinctio similique laudantium eveniet + quidem sit placeat possimus tempore dolorum inventore corporis atque + quae ad, nobis explicabo delectus. +

+
+
+ +
+
+
+
Name:
+
Samuel
+
+ +
+
Age:
+
28
+
+ +
+
Birthdate:
+
02.11.1995
+
+ +
+
City:
+
Berlin
+
+ +
+
Language:
+
English
+
+ +
+
Like Pizza:
+
Hell yeah
+
+
+
+
+ `, + styles: [''], +}) +export class AppComponent {} diff --git a/apps/angular/simple-animations/src/app/app.config.ts b/apps/angular/simple-animations/src/app/app.config.ts new file mode 100644 index 0000000..81a6edd --- /dev/null +++ b/apps/angular/simple-animations/src/app/app.config.ts @@ -0,0 +1,5 @@ +import { ApplicationConfig } from '@angular/core'; + +export const appConfig: ApplicationConfig = { + providers: [], +}; diff --git a/apps/angular/simple-animations/src/assets/.gitkeep b/apps/angular/simple-animations/src/assets/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/apps/angular/simple-animations/src/favicon.ico b/apps/angular/simple-animations/src/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..317ebcb2336e0833a22dddf0ab287849f26fda57 GIT binary patch literal 15086 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 + + + + angular-simple-animations + + + + + + + + diff --git a/apps/angular/simple-animations/src/main.ts b/apps/angular/simple-animations/src/main.ts new file mode 100644 index 0000000..f3a7223 --- /dev/null +++ b/apps/angular/simple-animations/src/main.ts @@ -0,0 +1,7 @@ +import { bootstrapApplication } from '@angular/platform-browser'; +import { AppComponent } from './app/app.component'; +import { appConfig } from './app/app.config'; + +bootstrapApplication(AppComponent, appConfig).catch((err) => + console.error(err), +); diff --git a/apps/angular/simple-animations/src/styles.scss b/apps/angular/simple-animations/src/styles.scss new file mode 100644 index 0000000..77e408a --- /dev/null +++ b/apps/angular/simple-animations/src/styles.scss @@ -0,0 +1,5 @@ +@tailwind base; +@tailwind components; +@tailwind utilities; + +/* You can add global styles to this file, and also import other style files */ diff --git a/apps/angular/simple-animations/src/test-setup.ts b/apps/angular/simple-animations/src/test-setup.ts new file mode 100644 index 0000000..15de72a --- /dev/null +++ b/apps/angular/simple-animations/src/test-setup.ts @@ -0,0 +1,2 @@ +import '@testing-library/jest-dom'; +import 'jest-preset-angular/setup-jest'; diff --git a/apps/angular/simple-animations/tailwind.config.js b/apps/angular/simple-animations/tailwind.config.js new file mode 100644 index 0000000..38183db --- /dev/null +++ b/apps/angular/simple-animations/tailwind.config.js @@ -0,0 +1,14 @@ +const { createGlobPatternsForDependencies } = require('@nx/angular/tailwind'); +const { join } = require('path'); + +/** @type {import('tailwindcss').Config} */ +module.exports = { + content: [ + join(__dirname, 'src/**/!(*.stories|*.spec).{ts,html}'), + ...createGlobPatternsForDependencies(__dirname), + ], + theme: { + extend: {}, + }, + plugins: [], +}; diff --git a/apps/angular/simple-animations/tsconfig.app.json b/apps/angular/simple-animations/tsconfig.app.json new file mode 100644 index 0000000..5822042 --- /dev/null +++ b/apps/angular/simple-animations/tsconfig.app.json @@ -0,0 +1,10 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "outDir": "../../../dist/out-tsc", + "types": [] + }, + "files": ["src/main.ts"], + "include": ["src/**/*.d.ts"], + "exclude": ["jest.config.ts", "src/**/*.test.ts", "src/**/*.spec.ts"] +} diff --git a/apps/angular/simple-animations/tsconfig.editor.json b/apps/angular/simple-animations/tsconfig.editor.json new file mode 100644 index 0000000..8ae117d --- /dev/null +++ b/apps/angular/simple-animations/tsconfig.editor.json @@ -0,0 +1,7 @@ +{ + "extends": "./tsconfig.json", + "include": ["src/**/*.ts"], + "compilerOptions": { + "types": ["jest", "node"] + } +} diff --git a/apps/angular/simple-animations/tsconfig.json b/apps/angular/simple-animations/tsconfig.json new file mode 100644 index 0000000..7a9f4b7 --- /dev/null +++ b/apps/angular/simple-animations/tsconfig.json @@ -0,0 +1,33 @@ +{ + "compilerOptions": { + "target": "es2022", + "useDefineForClassFields": false, + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "strict": true, + "noImplicitOverride": true, + "noPropertyAccessFromIndexSignature": true, + "noImplicitReturns": true, + "noFallthroughCasesInSwitch": true, + }, + "files": [], + "include": [], + "references": [ + { + "path": "./tsconfig.app.json", + }, + { + "path": "./tsconfig.spec.json", + }, + { + "path": "./tsconfig.editor.json", + }, + ], + "extends": "../../../tsconfig.base.json", + "angularCompilerOptions": { + "enableI18nLegacyMessageIdFormat": false, + "strictInjectionParameters": true, + "strictInputAccessModifiers": true, + "strictTemplates": true, + }, +} diff --git a/apps/angular/simple-animations/tsconfig.spec.json b/apps/angular/simple-animations/tsconfig.spec.json new file mode 100644 index 0000000..1a4817a --- /dev/null +++ b/apps/angular/simple-animations/tsconfig.spec.json @@ -0,0 +1,15 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "outDir": "../../dist/out-tsc", + "module": "commonjs", + "types": ["jest", "node", "@testing-library/jest-dom"] + }, + "files": ["src/test-setup.ts"], + "include": [ + "jest.config.ts", + "src/**/*.test.ts", + "src/**/*.spec.ts", + "src/**/*.d.ts" + ] +} diff --git a/challenge-number.json b/challenge-number.json index a48a4f1..95430ce 100644 --- a/challenge-number.json +++ b/challenge-number.json @@ -1,6 +1,6 @@ { - "total": 44, - "🟢": 16, + "total": 45, + "🟢": 17, "🟠": 120, "🔴": 208 } diff --git a/docs/src/content/docs/challenges/angular/44-view-transition.md b/docs/src/content/docs/challenges/angular/44-view-transition.md index 46ae580..6dbf211 100644 --- a/docs/src/content/docs/challenges/angular/44-view-transition.md +++ b/docs/src/content/docs/challenges/angular/44-view-transition.md @@ -6,7 +6,6 @@ challengeNumber: 44 command: angular-view-transition sidebar: order: 208 - badge: New --- ## Information diff --git a/docs/src/content/docs/challenges/angular/45-simple-animations.md b/docs/src/content/docs/challenges/angular/45-simple-animations.md new file mode 100644 index 0000000..839872b --- /dev/null +++ b/docs/src/content/docs/challenges/angular/45-simple-animations.md @@ -0,0 +1,38 @@ +--- +title: 🟢 Simple Animations +description: Challenge 45 is about learning angular's integrated animation API +author: sven-brodny +challengeNumber: 45 +command: angular-simple-animations +sidebar: + order: 17 + badge: New +--- + +## Information + +Well-designed animations can make your application more fun and straightforward to use, but they aren't just cosmetic. Animations can improve your application and user experience in a number of ways: + +- Without animations, web page transitions can seem abrupt and jarring +- Motion greatly enhances the user experience, so animations give users a chance to detect the application's response to their actions +- Good animations intuitively call the user's attention to where it is needed + +I would recommend you to read the [official documentation](https://angular.io/guide/animations). You will learn everything that is necessary to successfully complete the challenge. + +Otherwise look at this [working example](https://svenson95.github.io/ng-xmp-animations/) and [git repo](https://github.com/svenson95/ng-xmp-animations) to get inspired. + +## Statement + +The goal of this challenge is to add animations. + +## Constraints + +Don't use any css and utilize angular's integrated `@angular/animations` api. + +### Level 1 + +Add a fading or moving animation for the paragraphs on the left side + +### Level 2 + +Add a stagger animation for the list on the right side diff --git a/docs/src/content/docs/es/index.mdx b/docs/src/content/docs/es/index.mdx index e164844..12241fd 100644 --- a/docs/src/content/docs/es/index.mdx +++ b/docs/src/content/docs/es/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Ir al Desafío más reciente - link: /es/challenges/angular/43-signal-input/ + link: /es/challenges/angular/45-simple-animations/ icon: rocket - text: Dar una estrella link: https://github.com/tomalaforge/angular-challenges @@ -23,16 +23,16 @@ hero: import { Card, CardGrid } from '@astrojs/starlight/components'; import MyIcon from '../../../components/MyIcon.astro'; -import SubscriptionForm from '../../../components/SubscriptionForm.astro' +import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Este repositorio contiene 44 desafíos relacionados con Angular, Nx, RxJS, Ngrx y Typescript. + + Este repositorio contiene 45 Desafíos relacionados con Angular, Nx, RxJS, Ngrx y Typescript. Estos desafíos se resuelven en torno a problemas de la vida real o características específicas para mejorar tus habilidades. - + @@ -57,7 +57,8 @@ import SubscriptionForm from '../../../components/SubscriptionForm.astro' - Completar estos desafíos te preparará para cualquier desafío técnico que puedas encontrar en un rol de frontend durante las entrevistas. + Completar estos desafíos te preparará para cualquier desafío técnico que + puedas encontrar en un rol de frontend durante las entrevistas. diff --git a/docs/src/content/docs/fr/index.mdx b/docs/src/content/docs/fr/index.mdx index 892cda6..ae334e5 100644 --- a/docs/src/content/docs/fr/index.mdx +++ b/docs/src/content/docs/fr/index.mdx @@ -15,7 +15,7 @@ hero: icon: right-arrow variant: primary - text: Aller au dernier Challenge - link: /fr/challenges/angular/44-view-transition/ + link: /fr/challenges/angular/45-simple-animations/ icon: rocket - text: Donne une étoile link: https://github.com/tomalaforge/angular-challenges @@ -25,15 +25,15 @@ hero: import { Card, CardGrid } from '@astrojs/starlight/components'; import MyIcon from '../../../components/MyIcon.astro'; -import SubscriptionForm from '../../../components/SubscriptionForm.astro' +import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Ce répertoire rassemble 44 défis liés à Angular, Nx, RxJS, Ngrx et Typescript. Ces défis portent sur des problèmes réels ou des fonctionnalités spécifiques pour améliorer vos compétences. + + Ce répertoire rassemble 45 Défis liés à Angular, Nx, RxJS, Ngrx et Typescript. Ces défis portent sur des problèmes réels ou des fonctionnalités spécifiques pour améliorer vos compétences. - + diff --git a/docs/src/content/docs/index.mdx b/docs/src/content/docs/index.mdx index 968084a..7185c30 100644 --- a/docs/src/content/docs/index.mdx +++ b/docs/src/content/docs/index.mdx @@ -24,17 +24,16 @@ hero: import { Card, CardGrid } from '@astrojs/starlight/components'; import MyIcon from '../../components/MyIcon.astro'; -import SubscriptionForm from '../../components/SubscriptionForm.astro' - +import SubscriptionForm from '../../components/SubscriptionForm.astro'; - - This repository gathers 44 Challenges related to Angular, Nx, RxJS, Ngrx and Typescript. + + This repository gathers 45 Challenges related to Angular, Nx, RxJS, Ngrx and Typescript. These challenges resolve around real-life issues or specific features to elevate your skills. - + diff --git a/docs/src/content/docs/pt/index.mdx b/docs/src/content/docs/pt/index.mdx index 3004dae..3b2c198 100644 --- a/docs/src/content/docs/pt/index.mdx +++ b/docs/src/content/docs/pt/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Ir para o desafio mais recente - link: /pt/challenges/angular/44-view-transition/ + link: /pt/challenges/angular/45-simple-animations/ icon: rocket - text: Dar uma estrela link: https://github.com/tomalaforge/angular-challenges @@ -23,19 +23,20 @@ hero: import { Card, CardGrid } from '@astrojs/starlight/components'; import MyIcon from '../../../components/MyIcon.astro'; -import SubscriptionForm from '../../../components/SubscriptionForm.astro' +import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Este repositório possui 44 desafios relacionados a Angular, Nx, RxJS, + + Este repositório possui 45 Desafios relacionados a Angular, Nx, RxJS, Ngrx e Typescript. Esses desafios são voltados para problemas reais ou funcionalidades específicas afim de melhorar suas habilidades. - - - +{' '} + + + {' '} diff --git a/docs/src/content/docs/ru/index.mdx b/docs/src/content/docs/ru/index.mdx index ac0cb90..15f96ce 100644 --- a/docs/src/content/docs/ru/index.mdx +++ b/docs/src/content/docs/ru/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Перейти к последней задаче - link: /ru/challenges/angular/44-view-transition/ + link: /ru/challenges/angular/45-simple-animations/ icon: rocket - text: Добавить звезду link: https://github.com/tomalaforge/angular-challenges @@ -23,36 +23,38 @@ hero: import { Card, CardGrid } from '@astrojs/starlight/components'; import MyIcon from '../../../components/MyIcon.astro'; -import SubscriptionForm from '../../../components/SubscriptionForm.astro' +import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Этот репозиторий содержит 44 испытания, связанных с Angular, Nx, RxJS, Ngrx and Typescript. + + Этот репозиторий содержит 45 Испытания, связанных с Angular, Nx, RxJS, Ngrx and Typescript. Испытания основаны на реальных задачах или инструментах для того, чтобы прокачать вас. - + - Одна из целей этого репозитория снизить барьер для разработки - открытого программного обеспечения (OSS). Решив эти задачи, вы поймете, - как начать вносить свой вклад в любой другой проект с открытым исходным кодом. + Одна из целей этого репозитория снизить барьер для разработки открытого + программного обеспечения (OSS). Решив эти задачи, вы поймете, как начать + вносить свой вклад в любой другой проект с открытым исходным кодом. - Изучение и использование нового фреймворка всегда сопряжено с трудностями. - В этом наборе испытаний содержатся реальные примеры задач, чтобы закрепить на практике то, чему вы научились. - Любой может оставить комментарий или предложить помощь. + Изучение и использование нового фреймворка всегда сопряжено с трудностями. В + этом наборе испытаний содержатся реальные примеры задач, чтобы закрепить на + практике то, чему вы научились. Любой может оставить комментарий или + предложить помощь. - Учиться одному - здорово, но обучение вместе с другими поможет вам добиться большего. + Учиться одному - здорово, но обучение вместе с другими поможет вам добиться + большего. У вас есть идея или интересный баг? Не стесняйтесь;{' '} - Создавайте свои собственные испытания не теряя времени. + Создавайте свои собственные испытания не теряя времени. @@ -61,8 +63,9 @@ import SubscriptionForm from '../../../components/SubscriptionForm.astro' - Это бесплатный проект, и он будет оставаться таковым как можно дольше. - Однако вся работа ведется в мое свободное время, включая создание новых испытаний и ревью их решений(PRs). + Это бесплатный проект, и он будет оставаться таковым как можно дольше. Однако + вся работа ведется в мое свободное время, включая создание новых испытаний и + ревью их решений(PRs). Спонсорство может поддержать меня и способствовать развитию проекта. From 93b27177753d02d3ff17ef4fb8dc86b178ef0254 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Mon, 19 Feb 2024 23:58:41 +0100 Subject: [PATCH 02/12] refactor: simple animations challenge template --- .../src/app/app.component.ts | 72 +++++++++++-------- 1 file changed, 41 insertions(+), 31 deletions(-) diff --git a/apps/angular/simple-animations/src/app/app.component.ts b/apps/angular/simple-animations/src/app/app.component.ts index c194f4a..f3d710e 100644 --- a/apps/angular/simple-animations/src/app/app.component.ts +++ b/apps/angular/simple-animations/src/app/app.component.ts @@ -4,11 +4,24 @@ import { Component } from '@angular/core'; standalone: true, imports: [], selector: 'app-root', + styles: ` + .column { + @apply flex flex-1 flex-col gap-5; + } + + .list-item { + @apply flex flex-row border-b px-5 pb-2; + + span { + @apply flex-1; + } + } + `, template: `
-
+
-

2008

+

2008

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae mollitia sequi accusantium, distinctio similique laudantium eveniet @@ -18,7 +31,7 @@ import { Component } from '@angular/core';

-

2010

+

2010

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae mollitia sequi accusantium, distinctio similique laudantium eveniet @@ -28,7 +41,7 @@ import { Component } from '@angular/core';

-

2012

+

2012

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae mollitia sequi accusantium, distinctio similique laudantium eveniet @@ -38,41 +51,38 @@ import { Component } from '@angular/core';

-
-
-
-
Name:
-
Samuel
-
+
+
+ Name: + Samuel +
-
-
Age:
-
28
-
+
+ Age: + 28 +
-
-
Birthdate:
-
02.11.1995
-
+
+ Birthdate: + 02.11.1995 +
-
-
City:
-
Berlin
-
+
+ City: + Berlin +
-
-
Language:
-
English
-
+
+ Language: + English +
-
-
Like Pizza:
-
Hell yeah
-
+
+ Like Pizza: + Hell yeah
`, - styles: [''], }) export class AppComponent {} From 11106df4f49b4a38d11a468bbf4a28d99680539a Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 00:26:31 +0100 Subject: [PATCH 03/12] refactor: simple animations challenge template & delete spec --- .../src/app/app.component.spec.ts | 8 ------- .../src/app/app.component.ts | 22 +++++++++---------- 2 files changed, 11 insertions(+), 19 deletions(-) delete mode 100644 apps/angular/simple-animations/src/app/app.component.spec.ts diff --git a/apps/angular/simple-animations/src/app/app.component.spec.ts b/apps/angular/simple-animations/src/app/app.component.spec.ts deleted file mode 100644 index 3905d62..0000000 --- a/apps/angular/simple-animations/src/app/app.component.spec.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { render } from '@testing-library/angular'; -import { AppComponent } from './app.component'; - -describe('AppComponent', () => { - test('...', async () => { - await render(AppComponent); - }); -}); diff --git a/apps/angular/simple-animations/src/app/app.component.ts b/apps/angular/simple-animations/src/app/app.component.ts index f3d710e..9f537b3 100644 --- a/apps/angular/simple-animations/src/app/app.component.ts +++ b/apps/angular/simple-animations/src/app/app.component.ts @@ -5,7 +5,7 @@ import { Component } from '@angular/core'; imports: [], selector: 'app-root', styles: ` - .column { + section { @apply flex flex-1 flex-col gap-5; } @@ -19,8 +19,8 @@ import { Component } from '@angular/core'; `, template: `
-
-
+
+

2008

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae @@ -28,9 +28,9 @@ import { Component } from '@angular/core'; quidem sit placeat possimus tempore dolorum inventore corporis atque quae ad, nobis explicabo delectus.

-
+
-
+

2010

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae @@ -38,9 +38,9 @@ import { Component } from '@angular/core'; quidem sit placeat possimus tempore dolorum inventore corporis atque quae ad, nobis explicabo delectus.

-
+
-
+

2012

Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae @@ -48,10 +48,10 @@ import { Component } from '@angular/core'; quidem sit placeat possimus tempore dolorum inventore corporis atque quae ad, nobis explicabo delectus.

-
-
+
+ -
+
Name: Samuel @@ -81,7 +81,7 @@ import { Component } from '@angular/core'; Like Pizza: Hell yeah
-
+
`, }) From 022f997de81e008c96ed90064970d75e1e5130a3 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 08:05:30 +0100 Subject: [PATCH 04/12] fix(simple-animations): wrong author, challenge number & typos --- apps/angular/simple-animations/README.md | 4 ++-- challenge-number.json | 2 +- .../challenges/angular/45-simple-animations.md | 16 ++++++++-------- docs/src/content/docs/es/index.mdx | 2 +- docs/src/content/docs/fr/index.mdx | 2 +- docs/src/content/docs/pt/index.mdx | 3 ++- docs/src/content/docs/ru/index.mdx | 2 +- 7 files changed, 16 insertions(+), 15 deletions(-) diff --git a/apps/angular/simple-animations/README.md b/apps/angular/simple-animations/README.md index f151448..87e6c7e 100644 --- a/apps/angular/simple-animations/README.md +++ b/apps/angular/simple-animations/README.md @@ -1,6 +1,6 @@ # Simple Animations -> author: thomas-laforge +> author: sven-brodny ### Run Application @@ -10,4 +10,4 @@ npx nx serve angular-simple-animations ### Documentation and Instruction -Challenge documentation is [here](https://angular-challenges.vercel.app/challenges/angular/45-simple-animations/). +Challenge documentation is [here](https://angular-challenges.vercel.app/challenges/angular/46-simple-animations/). diff --git a/challenge-number.json b/challenge-number.json index 21805a0..bba17af 100644 --- a/challenge-number.json +++ b/challenge-number.json @@ -1,5 +1,5 @@ { - "total": 45, + "total": 46, "🟢": 17, "🟠": 120, "🔴": 209 diff --git a/docs/src/content/docs/challenges/angular/45-simple-animations.md b/docs/src/content/docs/challenges/angular/45-simple-animations.md index 839872b..29edaaf 100644 --- a/docs/src/content/docs/challenges/angular/45-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/45-simple-animations.md @@ -1,8 +1,8 @@ --- title: 🟢 Simple Animations -description: Challenge 45 is about learning angular's integrated animation API +description: Challenge 46 is about learning Angular's integrated animation API author: sven-brodny -challengeNumber: 45 +challengeNumber: 46 command: angular-simple-animations sidebar: order: 17 @@ -13,9 +13,9 @@ sidebar: Well-designed animations can make your application more fun and straightforward to use, but they aren't just cosmetic. Animations can improve your application and user experience in a number of ways: -- Without animations, web page transitions can seem abrupt and jarring -- Motion greatly enhances the user experience, so animations give users a chance to detect the application's response to their actions -- Good animations intuitively call the user's attention to where it is needed +- Without animations, web page transitions can seem abrupt and jarring. +- Motion greatly enhances the user experience, so animations give users a chance to detect the application's response to their actions. +- Good animations intuitively call the user's attention to where it is needed. I would recommend you to read the [official documentation](https://angular.io/guide/animations). You will learn everything that is necessary to successfully complete the challenge. @@ -27,12 +27,12 @@ The goal of this challenge is to add animations. ## Constraints -Don't use any css and utilize angular's integrated `@angular/animations` api. +Don't use any CSS and utilize Angular's integrated `@angular/animations` API. ### Level 1 -Add a fading or moving animation for the paragraphs on the left side +Add a fading or moving animation for the paragraphs on the left side. ### Level 2 -Add a stagger animation for the list on the right side +Add a stagger animation for the list on the right side. diff --git a/docs/src/content/docs/es/index.mdx b/docs/src/content/docs/es/index.mdx index 12241fd..f0b6d2a 100644 --- a/docs/src/content/docs/es/index.mdx +++ b/docs/src/content/docs/es/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Ir al Desafío más reciente - link: /es/challenges/angular/45-simple-animations/ + link: /es/challenges/angular/46-simple-animations/ icon: rocket - text: Dar una estrella link: https://github.com/tomalaforge/angular-challenges diff --git a/docs/src/content/docs/fr/index.mdx b/docs/src/content/docs/fr/index.mdx index ae334e5..3f05963 100644 --- a/docs/src/content/docs/fr/index.mdx +++ b/docs/src/content/docs/fr/index.mdx @@ -15,7 +15,7 @@ hero: icon: right-arrow variant: primary - text: Aller au dernier Challenge - link: /fr/challenges/angular/45-simple-animations/ + link: /fr/challenges/angular/46-simple-animations/ icon: rocket - text: Donne une étoile link: https://github.com/tomalaforge/angular-challenges diff --git a/docs/src/content/docs/pt/index.mdx b/docs/src/content/docs/pt/index.mdx index 3b2c198..f1c14ee 100644 --- a/docs/src/content/docs/pt/index.mdx +++ b/docs/src/content/docs/pt/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Ir para o desafio mais recente - link: /pt/challenges/angular/45-simple-animations/ + link: /pt/challenges/angular/46-simple-animations/ icon: rocket - text: Dar uma estrela link: https://github.com/tomalaforge/angular-challenges @@ -34,6 +34,7 @@ import SubscriptionForm from '../../../components/SubscriptionForm.astro';
{' '} + diff --git a/docs/src/content/docs/ru/index.mdx b/docs/src/content/docs/ru/index.mdx index 15f96ce..3e25ab4 100644 --- a/docs/src/content/docs/ru/index.mdx +++ b/docs/src/content/docs/ru/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Перейти к последней задаче - link: /ru/challenges/angular/45-simple-animations/ + link: /ru/challenges/angular/46-simple-animations/ icon: rocket - text: Добавить звезду link: https://github.com/tomalaforge/angular-challenges From 2cfee0ff48e0f8916e18bd8275f7bbfe8b5f0ab3 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 08:13:16 +0100 Subject: [PATCH 05/12] fix(simple-animations): file name with wrong challenge number --- .../angular/{45-simple-animations.md => 46-simple-animations.md} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/src/content/docs/challenges/angular/{45-simple-animations.md => 46-simple-animations.md} (100%) diff --git a/docs/src/content/docs/challenges/angular/45-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md similarity index 100% rename from docs/src/content/docs/challenges/angular/45-simple-animations.md rename to docs/src/content/docs/challenges/angular/46-simple-animations.md From 070f0ff6ee5aedb102c3b530a41f333044fde784 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 08:14:09 +0100 Subject: [PATCH 06/12] fix(simple-animations): wrong challenge numbers & wrong latest challenge --- README.md | 2 +- docs/src/content/docs/es/index.mdx | 4 ++-- docs/src/content/docs/fr/index.mdx | 4 ++-- docs/src/content/docs/index.mdx | 6 +++--- docs/src/content/docs/pt/index.mdx | 4 ++-- docs/src/content/docs/ru/index.mdx | 4 ++-- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index a350212..8d4d9a0 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ If you would like to propose a challenge, this project is open source, so feel f ## Challenges -Check [all 45 challenges](https://angular-challenges.vercel.app/) +Check [all 46 challenges](https://angular-challenges.vercel.app/) ## Contributors ✨ diff --git a/docs/src/content/docs/es/index.mdx b/docs/src/content/docs/es/index.mdx index f0b6d2a..deb8340 100644 --- a/docs/src/content/docs/es/index.mdx +++ b/docs/src/content/docs/es/index.mdx @@ -26,8 +26,8 @@ import MyIcon from '../../../components/MyIcon.astro'; import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Este repositorio contiene 45 Desafíos relacionados con Angular, Nx, RxJS, Ngrx y Typescript. + + Este repositorio contiene 46 Desafíos relacionados con Angular, Nx, RxJS, Ngrx y Typescript. Estos desafíos se resuelven en torno a problemas de la vida real o características específicas para mejorar tus habilidades. diff --git a/docs/src/content/docs/fr/index.mdx b/docs/src/content/docs/fr/index.mdx index 3f05963..d24f92a 100644 --- a/docs/src/content/docs/fr/index.mdx +++ b/docs/src/content/docs/fr/index.mdx @@ -28,8 +28,8 @@ import MyIcon from '../../../components/MyIcon.astro'; import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Ce répertoire rassemble 45 Défis liés à Angular, Nx, RxJS, Ngrx et Typescript. Ces défis portent sur des problèmes réels ou des fonctionnalités spécifiques pour améliorer vos compétences. + + Ce répertoire rassemble 46 Défis liés à Angular, Nx, RxJS, Ngrx et Typescript. Ces défis portent sur des problèmes réels ou des fonctionnalités spécifiques pour améliorer vos compétences. diff --git a/docs/src/content/docs/index.mdx b/docs/src/content/docs/index.mdx index b9a5715..a172533 100644 --- a/docs/src/content/docs/index.mdx +++ b/docs/src/content/docs/index.mdx @@ -13,7 +13,7 @@ hero: icon: right-arrow variant: primary - text: Go to the latest Challenge - link: /challenges/angular/45-react-in-angular/ + link: /challenges/angular/46-simple-animations/ icon: rocket - text: Give a star link: https://github.com/tomalaforge/angular-challenges @@ -27,8 +27,8 @@ import MyIcon from '../../components/MyIcon.astro'; import SubscriptionForm from '../../components/SubscriptionForm.astro'; - - This repository gathers 45 Challenges related to Angular, Nx, RxJS, Ngrx and Typescript. + + This repository gathers 46 Challenges related to Angular, Nx, RxJS, Ngrx and Typescript. These challenges resolve around real-life issues or specific features to elevate your skills. diff --git a/docs/src/content/docs/pt/index.mdx b/docs/src/content/docs/pt/index.mdx index f1c14ee..1c6de9b 100644 --- a/docs/src/content/docs/pt/index.mdx +++ b/docs/src/content/docs/pt/index.mdx @@ -26,8 +26,8 @@ import MyIcon from '../../../components/MyIcon.astro'; import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Este repositório possui 45 Desafios relacionados a Angular, Nx, RxJS, + + Este repositório possui 46 Desafios relacionados a Angular, Nx, RxJS, Ngrx e Typescript. Esses desafios são voltados para problemas reais ou funcionalidades específicas afim de melhorar suas habilidades. diff --git a/docs/src/content/docs/ru/index.mdx b/docs/src/content/docs/ru/index.mdx index 3e25ab4..77b9f61 100644 --- a/docs/src/content/docs/ru/index.mdx +++ b/docs/src/content/docs/ru/index.mdx @@ -26,8 +26,8 @@ import MyIcon from '../../../components/MyIcon.astro'; import SubscriptionForm from '../../../components/SubscriptionForm.astro'; - - Этот репозиторий содержит 45 Испытания, связанных с Angular, Nx, RxJS, Ngrx and Typescript. + + Этот репозиторий содержит 46 Испытания, связанных с Angular, Nx, RxJS, Ngrx and Typescript. Испытания основаны на реальных задачах или инструментах для того, чтобы прокачать вас. From dd83196c5780f9a41c019b87c30d930ac1efc495 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 08:26:45 +0100 Subject: [PATCH 07/12] docs(animations): add hint for related challenges --- docs/src/content/docs/challenges/angular/44-view-transition.md | 2 ++ .../src/content/docs/challenges/angular/46-simple-animations.md | 2 ++ .../content/docs/pt/challenges/angular/44-view-transition.md | 2 ++ 3 files changed, 6 insertions(+) diff --git a/docs/src/content/docs/challenges/angular/44-view-transition.md b/docs/src/content/docs/challenges/angular/44-view-transition.md index 6dbf211..c9550f6 100644 --- a/docs/src/content/docs/challenges/angular/44-view-transition.md +++ b/docs/src/content/docs/challenges/angular/44-view-transition.md @@ -10,6 +10,8 @@ sidebar: ## Information +This is the second of two animation challenges, the goal of this series is to master animations in Angular. + The View Transition API is a brand new API that provides a set of features that allow developers to control and manipulate the transitions and animations between views within an application. It plays a pivotal role in enhancing the user experience (UX), bringing applications to life with engaging and captivating transitions to guide users through different pages or sections of the app. diff --git a/docs/src/content/docs/challenges/angular/46-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md index 29edaaf..727ed63 100644 --- a/docs/src/content/docs/challenges/angular/46-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/46-simple-animations.md @@ -11,6 +11,8 @@ sidebar: ## Information +This is the first of two animation challenges, the goal of this series is to master animations in Angular. + Well-designed animations can make your application more fun and straightforward to use, but they aren't just cosmetic. Animations can improve your application and user experience in a number of ways: - Without animations, web page transitions can seem abrupt and jarring. diff --git a/docs/src/content/docs/pt/challenges/angular/44-view-transition.md b/docs/src/content/docs/pt/challenges/angular/44-view-transition.md index ead29d4..0d7e984 100644 --- a/docs/src/content/docs/pt/challenges/angular/44-view-transition.md +++ b/docs/src/content/docs/pt/challenges/angular/44-view-transition.md @@ -10,6 +10,8 @@ sidebar: ## Informação +Este é o segundo de três desafios animation, sendo o objetivo dominar animations em Angular. + A View Transition API é uma nova API que fornece um conjunto de funcionalidades, permitindo desenvolvedores controlarem e manipularem as transições e animações entre views dentro de uma aplicação. Isso tem um papel importante na melhoria da experiência do usuário (UX), trazendo vida a aplicações com transições atraentes e cativantes afim de guiar usuários por diferentes páginas e seções da aplicação. From 97ec15697346fb922e409090dde9ab80397adbce Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 09:02:46 +0100 Subject: [PATCH 08/12] fix: added missing author for new challenge --- docs/src/content/authors/sven-brodny.json | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 docs/src/content/authors/sven-brodny.json diff --git a/docs/src/content/authors/sven-brodny.json b/docs/src/content/authors/sven-brodny.json new file mode 100644 index 0000000..3372743 --- /dev/null +++ b/docs/src/content/authors/sven-brodny.json @@ -0,0 +1,5 @@ +{ + "name": "Sven Brodny", + "linkedin": "https://www.linkedin.com/in/sven-brodny-0ba603237/", + "github": "https://github.com/svenson95" +} From 25864887954cffcccc7340010b62dc79474f1fa9 Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Tue, 20 Feb 2024 17:57:04 +0100 Subject: [PATCH 09/12] docs(simple-animations): fix typo --- .../src/content/docs/challenges/angular/46-simple-animations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/content/docs/challenges/angular/46-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md index 727ed63..862085b 100644 --- a/docs/src/content/docs/challenges/angular/46-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/46-simple-animations.md @@ -19,7 +19,7 @@ Well-designed animations can make your application more fun and straightforward - Motion greatly enhances the user experience, so animations give users a chance to detect the application's response to their actions. - Good animations intuitively call the user's attention to where it is needed. -I would recommend you to read the [official documentation](https://angular.io/guide/animations). You will learn everything that is necessary to successfully complete the challenge. +I would recommend you read the [official documentation](https://angular.io/guide/animations). You will learn everything that is necessary to successfully complete the challenge. Otherwise look at this [working example](https://svenson95.github.io/ng-xmp-animations/) and [git repo](https://github.com/svenson95/ng-xmp-animations) to get inspired. From f40b9528acb79317a5cc0ca638d337b35986deae Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Wed, 21 Feb 2024 12:03:37 +0100 Subject: [PATCH 10/12] docs(simple-animations): improve statement & add stagger example video --- .../content/docs/challenges/angular/46-simple-animations.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/src/content/docs/challenges/angular/46-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md index 862085b..44966ae 100644 --- a/docs/src/content/docs/challenges/angular/46-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/46-simple-animations.md @@ -25,7 +25,7 @@ Otherwise look at this [working example](https://svenson95.github.io/ng-xmp-anim ## Statement -The goal of this challenge is to add animations. +The goal of this challenge is to add animations, they should run when the user arrives on the page or reload the page. ## Constraints @@ -38,3 +38,6 @@ Add a fading or moving animation for the paragraphs on the left side. ### Level 2 Add a stagger animation for the list on the right side. + + From fe1609686f01d94963ff7e668c37cf36a05525cf Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Wed, 21 Feb 2024 12:45:13 +0100 Subject: [PATCH 11/12] docs(simple-animations): add constraint how to trigger animation --- .../content/docs/challenges/angular/46-simple-animations.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/src/content/docs/challenges/angular/46-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md index 44966ae..03401c1 100644 --- a/docs/src/content/docs/challenges/angular/46-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/46-simple-animations.md @@ -29,7 +29,8 @@ The goal of this challenge is to add animations, they should run when the user a ## Constraints -Don't use any CSS and utilize Angular's integrated `@angular/animations` API. +- Don't use any CSS and utilize Angular's integrated `@angular/animations` API. +- Don't trigger the animations with a button like in the examples, rather when the user enter or reload the page. ### Level 1 From ca0306dc53bf67a34c000396723d4cde92e9034d Mon Sep 17 00:00:00 2001 From: Sven Brodny Date: Wed, 21 Feb 2024 12:53:57 +0100 Subject: [PATCH 12/12] docs(simple-animations): add example video for fade and moving animation --- .../content/docs/challenges/angular/46-simple-animations.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/src/content/docs/challenges/angular/46-simple-animations.md b/docs/src/content/docs/challenges/angular/46-simple-animations.md index 03401c1..f7c197a 100644 --- a/docs/src/content/docs/challenges/angular/46-simple-animations.md +++ b/docs/src/content/docs/challenges/angular/46-simple-animations.md @@ -36,9 +36,13 @@ The goal of this challenge is to add animations, they should run when the user a Add a fading or moving animation for the paragraphs on the left side. + + ### Level 2 Add a stagger animation for the list on the right side. +