mirror of
				https://github.com/explosion/spaCy.git
				synced 2025-10-31 07:57:35 +03:00 
			
		
		
		
	Add button option to terminal component
This commit is contained in:
		
							parent
							
								
									12954ab218
								
							
						
					
					
						commit
						9b4c38fe9f
					
				|  | @ -624,7 +624,7 @@ mixin qs(data, style) | |||
| //- Terminal-style code window | ||||
|     label - [string] title displayed in top bar of terminal window | ||||
| 
 | ||||
| mixin terminal(label) | ||||
| mixin terminal(label, button_text, button_url) | ||||
|     .x-terminal | ||||
|         .x-terminal__icons: span | ||||
|         .u-padding-small.u-text-label.u-text-center=label | ||||
|  | @ -632,6 +632,9 @@ mixin terminal(label) | |||
|         +code.x-terminal__code | ||||
|             block | ||||
| 
 | ||||
|         if button_text && button_url | ||||
|             +button(button_url, true, "primary", "small").x-terminal__button=button_text | ||||
| 
 | ||||
| 
 | ||||
| //- Landing | ||||
| 
 | ||||
|  |  | |||
|  | @ -6,6 +6,7 @@ | |||
|     padding: $border-radius | ||||
|     border-radius: 1em | ||||
|     width: 100% | ||||
|     position: relative | ||||
| 
 | ||||
| .x-terminal__icons | ||||
|     position: absolute | ||||
|  | @ -39,3 +40,13 @@ | |||
|     width: 100% | ||||
|     max-width: 100% | ||||
|     white-space: pre-wrap | ||||
| 
 | ||||
| 
 | ||||
| .x-terminal__button.x-terminal__button | ||||
|     @include position(absolute, bottom, right, 2.65rem, 2.6rem) | ||||
|     background: $color-dark | ||||
|     border-color: $color-dark | ||||
| 
 | ||||
|     &:hover | ||||
|         background: darken($color-dark, 5) | ||||
|         border-color: darken($color-dark, 5) | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user