-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2333 from codecrafters-io/expandable-list-hover-e…
…ffect expandable list hover effect
- Loading branch information
Showing
6 changed files
with
55 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
app/components/expandable-step-list/non-expandable-step.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<div class="py-2 px-1 cursor-not-allowed group/non-expandable-step relative" data-test-expandable-step-list-step ...attributes> | ||
<div class="flex items-center justify-between gap-2"> | ||
<div class="prose dark:prose-invert opacity-25" data-test-step-title> | ||
{{markdown-to-html (concat "**Step " @number "**: " @step.titleMarkdown)}} | ||
</div> | ||
</div> | ||
<div | ||
class="absolute inset-0 flex gap-1 items-center justify-center bg-white/70 dark:bg-gray-800/70 backdrop-blur-[3px] opacity-0 group-hover/non-expandable-step:opacity-100 transition-opacity" | ||
> | ||
{{svg-jar "information-circle" class="w-5 h-5 fill-current text-amber-500"}} | ||
<div class="text-sm text-amber-500 font-semibold" data-test-step-title> | ||
Complete previous step to expand this step | ||
</div> | ||
</div> | ||
</div> |
19 changes: 19 additions & 0 deletions
19
app/components/expandable-step-list/non-expandable-step.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import Component from '@glimmer/component'; | ||
import type { Step } from '../expandable-step-list'; | ||
|
||
interface Signature { | ||
Element: HTMLDivElement; | ||
|
||
Args: { | ||
number: number; | ||
step: Step; | ||
}; | ||
} | ||
|
||
export default class NonExpandableStepComponent extends Component<Signature> {} | ||
|
||
declare module '@glint/environment-ember-loose/registry' { | ||
export default interface Registry { | ||
'ExpandableStepList::NonExpandableStep': typeof NonExpandableStepComponent; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters