Skip to content

Commit

Permalink
chore: Add animations and move-cursor in "Reorder models" component
Browse files Browse the repository at this point in the history
This makes the usage feel more smoothly.
  • Loading branch information
MoritzWeber0 committed Dec 11, 2023
1 parent eeb96e5 commit de564a6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ <h2>Reorder models</h2>
class="my-[15px] rounded border border-solid"
>
@for (model of data.models; track model.id) {
<div cdkDrag class="flex items-center border-b border-solid">
<div
cdkDrag
class="flex cursor-move items-center border-b border-solid bg-white"
>
<span class="ml-[10px]">
<mat-icon class="mt-[10px] text-sm">reorder</mat-icon>
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ import {} from 'src/app/projects/service/project.service';
@Component({
selector: 'app-reorder-models',
templateUrl: './reorder-models-dialog.component.html',
styles: [
'.cdk-drag-placeholder { opacity: 0; }',
'.cdk-drag-animating { transition: transform 250ms cubic-bezier(0, 0, 0.2, 1); }',
],
})
export class ReorderModelsDialogComponent {
constructor(
Expand Down

0 comments on commit de564a6

Please sign in to comment.