format code

This commit is contained in:
myh 2023-12-26 20:32:01 +08:00
parent 0f43786e79
commit 0fda619b43
8 changed files with 40 additions and 37 deletions

View File

@ -2,7 +2,7 @@ import {ApplicationConfig} from '@angular/core';
import {provideRouter} from '@angular/router'; import {provideRouter} from '@angular/router';
import {routes} from './app.routes'; import {routes} from './app.routes';
import { provideAnimations } from '@angular/platform-browser/animations'; import {provideAnimations} from '@angular/platform-browser/animations';
export const appConfig: ApplicationConfig = { export const appConfig: ApplicationConfig = {
providers: [provideRouter(routes), provideAnimations()] providers: [provideRouter(routes), provideAnimations()]

View File

@ -1,5 +1,3 @@
import {Routes} from '@angular/router'; import {Routes} from '@angular/router';
export const routes: Routes = [ export const routes: Routes = [];
];

View File

@ -19,7 +19,7 @@
<li class="hover:text-blue-400">就把电话拔下来给他了</li> <li class="hover:text-blue-400">就把电话拔下来给他了</li>
</ul> </ul>
</div> </div>
<div class="flex flex-nowrap"> <div class="flex flex-nowrap">
<div class="ml-4 mr-1 shadow-lg w-1/2 h-auto rounded-lg border-2"> <div class="ml-4 mr-1 shadow-lg w-1/2 h-auto rounded-lg border-2">
<h1 class="px-3 pt-2 pb-0 text-2xl text-orange-600 font-bold"> <h1 class="px-3 pt-2 pb-0 text-2xl text-orange-600 font-bold">
@ -35,7 +35,7 @@
<li class="hover:text-blue-400">他按键的速度非常快但是只按01两个键</li> <li class="hover:text-blue-400">他按键的速度非常快但是只按01两个键</li>
</ul> </ul>
</div> </div>
<div class="mr-4 shadow-lg w-1/2 h-auto rounded-lg border-2"> <div class="mr-4 shadow-lg w-1/2 h-auto rounded-lg border-2">
<div class="h-auto"> <div class="h-auto">
<h1 class="px-3 pt-2 pb-0 text-2xl text-orange-600 font-bold flex-nowrap"> <h1 class="px-3 pt-2 pb-0 text-2xl text-orange-600 font-bold flex-nowrap">
@ -45,7 +45,7 @@
</span> </span>
</h1> </h1>
</div> </div>
<div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg"> <div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg">
<div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden"> <div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden">
我渐渐的有些困,我问他这东西要搞多久 我渐渐的有些困,我问他这东西要搞多久
@ -54,7 +54,7 @@
<img class="h-16 w-32" ngSrc="/assets/img/picture.png" alt="" height="601" width="900"/> <img class="h-16 w-32" ngSrc="/assets/img/picture.png" alt="" height="601" width="900"/>
</div> </div>
</div> </div>
<div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg"> <div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg">
<div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden"> <div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden">
他说要几个小时 他说要几个小时
@ -63,7 +63,7 @@
<img class="h-16 w-32" ngSrc="/assets/img/picture.png" alt="" height="601" width="900"/> <img class="h-16 w-32" ngSrc="/assets/img/picture.png" alt="" height="601" width="900"/>
</div> </div>
</div> </div>
<div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg"> <div class="flex border-2 rounded-lg m-2 p-0 h-auto justify-between flex-nowrap hover:text-blue-500 hover:shadow-lg">
<div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden"> <div class="h-16 w-1/2 leading-16 pl-3 overflow-hidden">
我给他倒了杯茶,就一个人去隔壁睡觉了 我给他倒了杯茶,就一个人去隔壁睡觉了
@ -75,7 +75,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="w-2/5 flex-grow mb-4"> <div class="w-2/5 flex-grow mb-4">
<div class="h-full my-4 mr-4 shadow-lg rounded-lg border-2"> <div class="h-full my-4 mr-4 shadow-lg rounded-lg border-2">
<h1 class="px-6 pt-4 pb-0 text-2xl text-orange-600 font-bold"> <h1 class="px-6 pt-4 pb-0 text-2xl text-orange-600 font-bold">

View File

@ -3,28 +3,28 @@
@tailwind components; @tailwind components;
.li-img li { .li-img li {
list-style: none; list-style: none;
float: left; float: left;
width: 25%; /*四列图片排列*/ width: 25%; /*四列图片排列*/
height: 175px; height: 175px;
overflow: hidden; overflow: hidden;
} }
.li-img li img { .li-img li img {
position: relative; position: relative;
width: 100%; width: 100%;
height: auto; height: auto;
top: 50%; /*li高度的一半*/ top: 50%; /*li高度的一半*/
transform: translateY(-50%); /*再向上移动自身的50%*/ transform: translateY(-50%); /*再向上移动自身的50%*/
} }
/*清除浮动*/ /*清除浮动*/
.clearfix:after { .clearfix:after {
position: relative; position: relative;
content: ''; content: '';
display: block; display: block;
width: 0; width: 0;
height: 0; height: 0;
visibility: hidden; visibility: hidden;
clear: both; clear: both;
} }

View File

@ -5,7 +5,7 @@
[pauseOnFocus]="pauseOnFocus" [pauseOnFocus]="pauseOnFocus"
(slide)="onSlide($event)" (slide)="onSlide($event)"
> >
@for (img of images;track img;let i = $index) { @for (img of images; track img; let i = $index) {
<ng-template ngbSlide> <ng-template ngbSlide>
<div class="carousel-caption"> <div class="carousel-caption">
<h3>My slide {{ i + 1 }} title</h3> <h3>My slide {{ i + 1 }} title</h3>

View File

@ -10,6 +10,6 @@
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"> <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
</head> </head>
<body class="mat-typography"> <body class="mat-typography">
<app-root></app-root> <app-root></app-root>
</body> </body>
</html> </html>

View File

@ -1,4 +1,3 @@
// Custom Theming for Angular Material // Custom Theming for Angular Material
// For more information: https://material.angular.io/guide/theming // For more information: https://material.angular.io/guide/theming
@use '@angular/material' as mat; @use '@angular/material' as mat;
@ -21,11 +20,11 @@ $AngularDemo-warn: mat.define-palette(mat.$red-palette);
// Create the theme object. A theme consists of configurations for individual // Create the theme object. A theme consists of configurations for individual
// theming systems such as "color" or "typography". // theming systems such as "color" or "typography".
$AngularDemo-theme: mat.define-light-theme(( $AngularDemo-theme: mat.define-light-theme((
color: ( color: (
primary: $AngularDemo-primary, primary: $AngularDemo-primary,
accent: $AngularDemo-accent, accent: $AngularDemo-accent,
warn: $AngularDemo-warn, warn: $AngularDemo-warn,
) )
)); ));
// Include theme styles for core and each component used in your app. // Include theme styles for core and each component used in your app.
@ -38,8 +37,14 @@ $AngularDemo-theme: mat.define-light-theme((
@tailwind components; @tailwind components;
@tailwind utilities; @tailwind utilities;
html, body { height: 100%; } html, body {
body { margin: 0; font-family: Roboto, "Helvetica Neue", sans-serif; } height: 100%;
}
body {
margin: 0;
font-family: Roboto, "Helvetica Neue", sans-serif;
}
/* Importing Bootstrap SCSS file. */ /* Importing Bootstrap SCSS file. */
@import 'bootstrap/scss/bootstrap'; @import 'bootstrap/scss/bootstrap';