Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix features page style #3161

Merged
merged 1 commit into from
Mar 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/sites/src/views/features.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class="ti-p48">
<div class="w1000 !mx-auto markdown-body">
<div class="ti-mw1000 !mx-auto markdown-body">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The class name change from w1000 to ti-mw1000 should be verified to ensure it aligns with the intended design specifications and does not affect layout negatively.

<h1 class="ti-f-r ti-f-box-center">
组件特性列表
<tiny-tag size="small" type="success" :title="`${componentCount} components`" class="ml8">{{
Expand Down
6 changes: 4 additions & 2 deletions examples/sites/tiny-uno/rules/size.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ const _s = {

w: 'width',
h: 'height',
mw: 'max-width',
mh: 'max-height',

r: '-right',
l: '-left',
Expand All @@ -18,9 +20,9 @@ export default function builder(option) {
return {
rules: [
// 高宽, 字体,行高 f12 lh20 w200 h200 box78
[/^(w|h)(\d+)$/, ([, attr, num]) => ({ [`${_s[attr]}`]: $t(num) })],
[/^(w|h|mw|mh)(\d+)$/, ([, attr, num]) => ({ [`${_s[attr]}`]: $t(num) })],

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the addition of mw and mh rules does not conflict with existing styles or introduce unexpected behavior in other components.

// 高宽百分比 wp33 hp50
[/^(w|h)p(\d+)$/, ([, attr, num]) => ({ [`${_s[attr]}`]: `${num}%` })],
[/^(w|h|mw|mh)p(\d+)$/, ([, attr, num]) => ({ [`${_s[attr]}`]: `${num}%` })],

// 内外边距 *可负* m10 mr10 mt-10 mx20 my-10 p10 pr10
[/^([mp])([rlbt]?)(-?\d+)$/, ([, attr, pos, num]) => ({ [`${_s[attr]}${pos ? _s[pos] : ''}`]: $t(num) })],
Expand Down
Loading