Skip to content

Commit c816d86

Browse files
author
Vasilii Boldurean
committed
Revert: tailwind sorting class names
1 parent 69f0443 commit c816d86

11 files changed

+26
-23
lines changed

src/components/Layout/Toc.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export function Toc({headings}: {headings: Toc}) {
1616
<nav role="navigation" className="pt-20 sticky top-0 right-0">
1717
{headings.length > 0 && (
1818
<h2 className="mb-3 lg:mb-3 uppercase tracking-wide font-bold text-sm text-secondary dark:text-secondary-dark px-4 w-full">
19-
On this page
19+
На этой странице
2020
</h2>
2121
)}
2222
<div

src/components/MDX/Challenges/Challenge.tsx

+9-8
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ export function Challenge({
5050
className="text-xl text-primary dark:text-primary-dark mb-2 mt-0 font-medium"
5151
id={currentChallenge.id}>
5252
<div className="font-bold block md:inline">
53-
{isRecipes ? 'Example' : 'Challenge'} {currentChallenge.order} of{' '}
53+
{isRecipes ? 'Пример' : 'Испытание'} {currentChallenge.order} из{' '}
5454
{totalChallenges}
5555
<span className="text-primary dark:text-primary-dark">: </span>
5656
</div>
@@ -63,14 +63,14 @@ export function Challenge({
6363
<div>
6464
<Button className="mr-2" onClick={toggleHint} active={showHint}>
6565
<IconHint className="mr-1.5" />{' '}
66-
{showHint ? 'Hide hint' : 'Show hint'}
66+
{showHint ? 'Скрыть подсказку' : 'Показать подсказку'}
6767
</Button>
6868
<Button
6969
className="mr-2"
7070
onClick={toggleSolution}
7171
active={showSolution}>
7272
<IconSolution className="mr-1.5" />{' '}
73-
{showSolution ? 'Hide solution' : 'Show solution'}
73+
{showSolution ? 'Скрыть решение' : 'Показать решение'}
7474
</Button>
7575
</div>
7676
) : (
@@ -80,7 +80,7 @@ export function Challenge({
8080
onClick={toggleSolution}
8181
active={showSolution}>
8282
<IconSolution className="mr-1.5" />{' '}
83-
{showSolution ? 'Hide solution' : 'Show solution'}
83+
{showSolution ? 'Скрыть решение' : 'Показать решение'}
8484
</Button>
8585
)
8686
)}
@@ -94,7 +94,8 @@ export function Challenge({
9494
)}
9595
onClick={handleClickNextChallenge}
9696
active>
97-
Next {isRecipes ? 'Example' : 'Challenge'}
97+
{isRecipes ? 'Следующий' : 'Следующее'}{' '}
98+
{isRecipes ? 'Пример' : 'Испытание'}
9899
<IconArrowSmall displayDirection="right" className="block ml-1.5" />
99100
</Button>
100101
)}
@@ -104,12 +105,12 @@ export function Challenge({
104105
{showSolution && (
105106
<div className="mt-6">
106107
<h3 className="text-2xl font-bold text-primary dark:text-primary-dark">
107-
Solution
108+
Решение
108109
</h3>
109110
{currentChallenge.solution}
110111
<div className="flex justify-between items-center mt-4">
111112
<Button onClick={() => setShowSolution(false)}>
112-
Close solution
113+
Скрыть решение
113114
</Button>
114115
{hasNextChallenge && (
115116
<Button
@@ -118,7 +119,7 @@ export function Challenge({
118119
)}
119120
onClick={handleClickNextChallenge}
120121
active>
121-
Next Challenge
122+
Следующее Испытание
122123
<IconArrowSmall
123124
displayDirection="right"
124125
className="block ml-1.5"

src/components/MDX/Challenges/Challenges.tsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,9 @@ export function Challenges({
7878
children,
7979
isRecipes,
8080
noTitle,
81-
titleText = isRecipes ? 'Try out some examples' : 'Try out some challenges',
81+
titleText = isRecipes
82+
? 'Попробуйте несколько примеров'
83+
: 'Выполните несколько задач',
8284
titleId = isRecipes ? 'examples' : 'challenges',
8385
}: ChallengesProps) {
8486
const challenges = parseChallengeContents(children);

src/components/MDX/ExpandableExample.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ function ExpandableExample({children, excerpt, type}: ExpandableExampleProps) {
7171
{isDeepDive && (
7272
<>
7373
<IconDeepDive className="inline mr-2 dark:text-purple-30 text-purple-40" />
74-
Deep Dive
74+
Глубокое Погружение
7575
</>
7676
)}
7777
{isExample && (
@@ -101,7 +101,7 @@ function ExpandableExample({children, excerpt, type}: ExpandableExampleProps) {
101101
<span className="mr-1">
102102
<IconChevron displayDirection={isExpanded ? 'up' : 'down'} />
103103
</span>
104-
{isExpanded ? 'Hide Details' : 'Show Details'}
104+
{isExpanded ? 'Скрыть подробности' : 'Показать подробности'}
105105
</Button>
106106
</summary>
107107
<div

src/components/MDX/MDXComponents.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ function YouWillLearn({
173173
children: any;
174174
isChapter?: boolean;
175175
}) {
176-
let title = isChapter ? 'In this chapter' : 'You will learn';
176+
let title = isChapter ? 'В этой главе' : 'Вы изучите';
177177
return <SimpleCallout title={title}>{children}</SimpleCallout>;
178178
}
179179

src/components/MDX/Recap.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ function Recap({children}: RecapProps) {
1313
return (
1414
<section>
1515
<H2 isPageAnchor id="recap">
16-
Recap
16+
Подведение итогов
1717
</H2>
1818
{children}
1919
</section>

src/components/MDX/Sandpack/CustomPreset.tsx

+3-3
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ const SandboxShell = memo(function SandboxShell({
7474
return (
7575
<>
7676
<div
77-
className="shadow-lg dark:shadow-lg-dark rounded-lg"
77+
className="rounded-lg shadow-lg dark:shadow-lg-dark"
7878
ref={containerRef}
7979
style={{
8080
contain: 'content',
@@ -95,7 +95,7 @@ const SandboxShell = memo(function SandboxShell({
9595
{(isExpandable || isExpanded) && (
9696
<button
9797
translate="yes"
98-
className="sandpack-expand flex text-base justify-between dark:border-card-dark bg-wash dark:bg-card-dark items-center z-10 p-1 w-full order-2 xl:order-last border-b-1 relative top-0"
98+
className="relative top-0 z-10 flex items-center justify-between order-2 w-full p-1 text-base sandpack-expand dark:border-card-dark bg-wash dark:bg-card-dark xl:order-last border-b-1"
9999
onClick={() => {
100100
const nextIsExpanded = !isExpanded;
101101
flushSync(() => {
@@ -119,7 +119,7 @@ const SandboxShell = memo(function SandboxShell({
119119
className="inline mr-1.5 text-xl"
120120
displayDirection={isExpanded ? 'up' : 'down'}
121121
/>
122-
{isExpanded ? 'Show less' : 'Show more'}
122+
{isExpanded ? 'Скрыть' : 'Раскрыть'}
123123
</span>
124124
</button>
125125
)}

src/components/MDX/Sandpack/DownloadButton.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ ${css}
100100
onClick={downloadHTML}
101101
title="Download Sandbox"
102102
type="button">
103-
<IconDownload className="inline mr-1" /> Download
103+
<IconDownload className="inline mr-1" /> Загрузить
104104
</button>
105105
);
106106
}

src/components/MDX/Sandpack/OpenInCodeSandboxButton.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export const OpenInCodeSandboxButton = () => {
1515
width="1em"
1616
height="1em"
1717
/>
18-
<span className="hidden md:block">Fork</span>
18+
<span className="hidden md:block">Отрыть в песочнице</span>
1919
</UnstyledOpenInCodeSandboxButton>
2020
);
2121
};

src/components/MDX/Sandpack/ResetButton.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export function ResetButton({onReset}: ResetButtonProps) {
1515
onClick={onReset}
1616
title="Reset Sandbox"
1717
type="button">
18-
<IconRestart className="inline ml-1 mr-1 relative" /> Reset
18+
<IconRestart className="relative inline ml-1 mr-1" /> Сбросить
1919
</button>
2020
);
2121
}

src/utils/prepareMDX.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ function getTableOfContents(children, depth) {
6565
if (anchors.length > 0) {
6666
anchors.unshift({
6767
url: '#',
68-
text: 'Overview',
68+
text: 'Обзор',
6969
depth: 2,
7070
});
7171
}
@@ -88,13 +88,13 @@ function extractHeaders(children, depth, out) {
8888
header = {
8989
url: '#challenges',
9090
depth: 2,
91-
text: 'Challenges',
91+
text: 'Испытания',
9292
};
9393
} else if (child.type === 'Recap') {
9494
header = {
9595
url: '#recap',
9696
depth: 2,
97-
text: 'Recap',
97+
text: 'Подведение итогов',
9898
};
9999
} else if (child.type === 'TeamMember') {
100100
header = {

0 commit comments

Comments
 (0)