Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 | 'use client' import { css } from '@styled/css' interface DifficultyMethodSelectorProps { currentMethod: 'custom' | 'mastery' onChange: (method: 'custom' | 'mastery') => void isDark?: boolean } export function DifficultyMethodSelector({ currentMethod, onChange, isDark = false, }: DifficultyMethodSelectorProps) { return ( <div data-component="difficulty-method-selector"> {/* Tab buttons */} <div className={css({ display: 'flex', gap: '0', borderBottom: '2px solid', borderColor: isDark ? 'gray.700' : 'gray.200', })} > {/* Custom Difficulty Tab */} <button type="button" data-action="select-smart" onClick={() => onChange('custom')} className={css({ display: 'flex', alignItems: 'center', justifyContent: 'center', gap: '2', px: '5', py: '3', flex: '1', bg: currentMethod === 'custom' ? (isDark ? 'gray.800' : 'white') : 'transparent', color: currentMethod === 'custom' ? isDark ? 'brand.300' : 'brand.600' : isDark ? 'gray.500' : 'gray.500', fontWeight: currentMethod === 'custom' ? 'bold' : 'medium', fontSize: 'sm', borderTopLeftRadius: 'lg', borderTopRightRadius: 'lg', cursor: 'pointer', transition: 'all 0.2s', borderBottom: '3px solid', borderColor: currentMethod === 'custom' ? (isDark ? 'brand.500' : 'brand.500') : 'transparent', mb: '-2px', _hover: { color: currentMethod === 'custom' ? isDark ? 'brand.200' : 'brand.700' : isDark ? 'gray.400' : 'gray.600', bg: currentMethod === 'custom' ? isDark ? 'gray.800' : 'white' : isDark ? 'gray.800/30' : 'gray.50', }, })} > <span>🎯</span> <span>Custom Difficulty</span> </button> {/* Mastery Progression Tab */} <button type="button" data-action="select-mastery" onClick={() => onChange('mastery')} className={css({ display: 'flex', alignItems: 'center', justifyContent: 'center', gap: '2', px: '5', py: '3', flex: '1', bg: currentMethod === 'mastery' ? (isDark ? 'gray.800' : 'white') : 'transparent', color: currentMethod === 'mastery' ? isDark ? 'brand.300' : 'brand.600' : isDark ? 'gray.500' : 'gray.500', fontWeight: currentMethod === 'mastery' ? 'bold' : 'medium', fontSize: 'sm', borderTopLeftRadius: 'lg', borderTopRightRadius: 'lg', cursor: 'pointer', transition: 'all 0.2s', borderBottom: '3px solid', borderColor: currentMethod === 'mastery' ? (isDark ? 'brand.500' : 'brand.500') : 'transparent', mb: '-2px', _hover: { color: currentMethod === 'mastery' ? isDark ? 'brand.200' : 'brand.700' : isDark ? 'gray.400' : 'gray.600', bg: currentMethod === 'mastery' ? isDark ? 'gray.800' : 'white' : isDark ? 'gray.800/30' : 'gray.50', }, })} > <span>🎓</span> <span>Mastery Progression</span> </button> </div> {/* Description text */} <div className={css({ mt: '2', px: '1', fontSize: 'xs', color: isDark ? 'gray.400' : 'gray.600', textAlign: 'center', })} > {currentMethod === 'custom' ? 'Choose a difficulty preset, then customize display options below' : 'Follow a structured skill progression with recommended scaffolding'} </div> </div> ) } |