mirror of
				https://github.com/crater-invoice/crater.git
				synced 2025-10-30 13:11:08 -04:00 
			
		
		
		
	Compare commits
	
		
			2 Commits
		
	
	
		
			dark-base-
			...
			dark-multi
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 6abb76b1b9 | |||
| 97be70e88c | 
| @ -437,21 +437,22 @@ export default { | |||||||
|       required: false, |       required: false, | ||||||
|       default: () => ({ |       default: () => ({ | ||||||
|         container: |         container: | ||||||
|           'p-0 relative mx-auto w-full flex items-center justify-end box-border cursor-pointer border border-gray-200 rounded-md bg-white text-sm leading-snug outline-none max-h-10', |           'p-0 relative mx-auto w-full flex items-center justify-end box-border cursor-pointer border border-gray-200 dark:border-gray-600 rounded-md bg-white dark:bg-gray-700 text-sm leading-snug outline-none max-h-10', | ||||||
|         containerDisabled: |         containerDisabled: | ||||||
|           'cursor-default bg-gray-200 bg-opacity-50 !text-gray-400', |           'bg-gray-200 bg-opacity-50 !text-gray-400 dark:!text-gray-800 !dark:text-gray-500 !cursor-default dark:opacity-25', | ||||||
|         containerOpen: '', |         containerOpen: '', | ||||||
|         containerOpenTop: '', |         containerOpenTop: '', | ||||||
|         containerActive: 'ring-1 ring-primary-400 border-primary-400', |         containerActive: 'ring-1 ring-primary-400 border-primary-400', | ||||||
|         containerInvalid: |         containerInvalid: | ||||||
|           'border-red-400 ring-red-400 focus:ring-red-400 focus:border-red-400', |           'border-red-500 ring-red-500 focus:ring-red-500 focus:border-red-500 dark:border-red-500 dark:ring-red-500 dark:focus:ring-red-500 dark:focus:border-red-500', | ||||||
|         containerInvalidActive: 'ring-1 border-red-400 ring-red-400', |         containerInvalidActive: | ||||||
|  |           'ring-1 border-red-500 ring-red-500 dark:ring-1 dark:border-red-500 dark:ring-red-500', | ||||||
|         singleLabel: |         singleLabel: | ||||||
|           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5', |           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5 dark:text-white', | ||||||
|         multipleLabel: |         multipleLabel: | ||||||
|           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5', |           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5 dark:text-white', | ||||||
|         search: |         search: | ||||||
|           'w-full absolute inset-0 outline-none appearance-none box-border border-0 text-sm font-sans bg-white rounded-md pl-3.5', |           'w-full absolute inset-0 outline-none appearance-none box-border border-0 text-sm font-sans bg-white rounded-md pl-3.5 border-transparent focus:border-transparent focus:ring-0 dark:bg-gray-700 dark:text-white', | ||||||
|         tags: 'grow shrink flex flex-wrap mt-1 pl-2', |         tags: 'grow shrink flex flex-wrap mt-1 pl-2', | ||||||
|         tag: 'bg-primary-500 text-white text-sm font-semibold py-0.5 pl-2 rounded mr-1 mb-1 flex items-center whitespace-nowrap', |         tag: 'bg-primary-500 text-white text-sm font-semibold py-0.5 pl-2 rounded mr-1 mb-1 flex items-center whitespace-nowrap', | ||||||
|         tagDisabled: 'pr-2 !bg-gray-400 text-white', |         tagDisabled: 'pr-2 !bg-gray-400 text-white', | ||||||
| @ -461,12 +462,12 @@ export default { | |||||||
|           'bg-multiselect-remove text-white bg-center bg-no-repeat opacity-30 inline-block w-3 h-3 group-hover:opacity-60', |           'bg-multiselect-remove text-white bg-center bg-no-repeat opacity-30 inline-block w-3 h-3 group-hover:opacity-60', | ||||||
|         tagsSearchWrapper: 'inline-block relative mx-1 mb-1 grow shrink h-full', |         tagsSearchWrapper: 'inline-block relative mx-1 mb-1 grow shrink h-full', | ||||||
|         tagsSearch: |         tagsSearch: | ||||||
|           'absolute inset-0 border-0 focus:outline-none !shadow-none !focus:shadow-none appearance-none p-0 text-sm font-sans box-border w-full', |           'absolute inset-0 border-0 focus:outline-none !shadow-none !focus:shadow-none appearance-none p-0 sm:text-sm font-sans box-border w-full dark:bg-gray-700', | ||||||
|         tagsSearchCopy: 'invisible whitespace-pre-wrap inline-block h-px', |         tagsSearchCopy: 'invisible whitespace-pre-wrap inline-block h-px', | ||||||
|         placeholder: |         placeholder: | ||||||
|           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5 text-gray-400 text-sm', |           'flex items-center h-full absolute left-0 top-0 pointer-events-none bg-transparent leading-snug pl-3.5 text-gray-400 sm:text-sm dark:text-gray-500', | ||||||
|         caret: |         caret: | ||||||
|           'bg-multiselect-caret bg-center bg-no-repeat w-5 h-5 py-px box-content z-5 relative mr-1 opacity-40 shrink-0 grow-0 transition-transform', |           'bg-multiselect-caret-black dark:bg-multiselect-caret-white bg-center bg-no-repeat w-5 h-5 py-px box-content z-5 relative mr-1 opacity-40 shrink-0 grow-0 transition-transform dark:text-white', | ||||||
|         caretOpen: 'rotate-180 pointer-events-auto', |         caretOpen: 'rotate-180 pointer-events-auto', | ||||||
|         clear: |         clear: | ||||||
|           'pr-3.5 relative z-10 opacity-40 transition duration-300 shrink-0 grow-0 flex hover:opacity-80', |           'pr-3.5 relative z-10 opacity-40 transition duration-300 shrink-0 grow-0 flex hover:opacity-80', | ||||||
| @ -475,7 +476,7 @@ export default { | |||||||
|         spinner: |         spinner: | ||||||
|           'bg-multiselect-spinner bg-center bg-no-repeat w-4 h-4 z-10 mr-3.5 animate-spin shrink-0 grow-0', |           'bg-multiselect-spinner bg-center bg-no-repeat w-4 h-4 z-10 mr-3.5 animate-spin shrink-0 grow-0', | ||||||
|         dropdown: |         dropdown: | ||||||
|           'max-h-60 shadow-lg absolute -left-px -right-px -bottom-1 translate-y-full border border-gray-300 mt-1 overflow-y-auto z-50 bg-white flex flex-col rounded-md', |           'max-h-60 shadow-lg absolute -left-px -right-px -bottom-1 translate-y-full border border-gray-300 mt-1 overflow-y-auto z-50 bg-white dark:border-gray-600 flex flex-col rounded-md dark:bg-gray-800 dark:shadow-glass', | ||||||
|         dropdownTop: |         dropdownTop: | ||||||
|           '-translate-y-full -top-2 bottom-auto flex-col-reverse rounded-md', |           '-translate-y-full -top-2 bottom-auto flex-col-reverse rounded-md', | ||||||
|         dropdownHidden: 'hidden', |         dropdownHidden: 'hidden', | ||||||
| @ -483,7 +484,7 @@ export default { | |||||||
|         optionsTop: 'flex-col-reverse', |         optionsTop: 'flex-col-reverse', | ||||||
|         group: 'p-0 m-0', |         group: 'p-0 m-0', | ||||||
|         groupLabel: |         groupLabel: | ||||||
|           'flex text-sm box-border items-center justify-start text-left py-1 px-3 font-semibold bg-gray-200 cursor-default leading-normal', |           'flex text-sm box-border items-center justify-start text-left py-1 px-3 font-semibold bg-gray-200 dark:bg-gray-700 dark:text-gray-400 cursor-default leading-normal', | ||||||
|         groupLabelPointable: 'cursor-pointer', |         groupLabelPointable: 'cursor-pointer', | ||||||
|         groupLabelPointed: 'bg-gray-300 text-gray-700', |         groupLabelPointed: 'bg-gray-300 text-gray-700', | ||||||
|         groupLabelSelected: 'bg-primary-600 text-white', |         groupLabelSelected: 'bg-primary-600 text-white', | ||||||
| @ -493,15 +494,18 @@ export default { | |||||||
|           'text-primary-100 bg-primary-600 bg-opacity-50 cursor-not-allowed', |           'text-primary-100 bg-primary-600 bg-opacity-50 cursor-not-allowed', | ||||||
|         groupOptions: 'p-0 m-0', |         groupOptions: 'p-0 m-0', | ||||||
|         option: |         option: | ||||||
|           'flex items-center justify-start box-border text-left cursor-pointer text-sm leading-snug py-2 px-3', |           'flex items-center justify-start box-border text-left cursor-pointer text-sm leading-snug py-2 px-3 dark:text-gray-200', | ||||||
|         optionPointed: 'text-gray-800 bg-gray-100', |         optionPointed: | ||||||
|  |           'text-gray-800 bg-gray-100 dark:text-white dark:bg-gray-700/30', | ||||||
|         optionSelected: 'text-white bg-primary-500', |         optionSelected: 'text-white bg-primary-500', | ||||||
|         optionDisabled: 'text-gray-300 cursor-not-allowed', |         optionDisabled: 'text-gray-300 cursor-not-allowed dark:text-gray-400', | ||||||
|         optionSelectedPointed: 'text-white bg-primary-500 opacity-90', |         optionSelectedPointed: 'text-white bg-primary-500 opacity-90', | ||||||
|         optionSelectedDisabled: |         optionSelectedDisabled: | ||||||
|           'text-primary-100 bg-primary-500 bg-opacity-50 cursor-not-allowed', |           'text-primary-100 bg-primary-500 bg-opacity-50 cursor-not-allowed', | ||||||
|         noOptions: 'py-2 px-3 text-gray-600 bg-white', |         noOptions: | ||||||
|         noResults: 'py-2 px-3 text-gray-600 bg-white', |           'py-2 px-3 text-gray-600 bg-white dark:bg-gray-700 dark:text-gray-200', | ||||||
|  |         noResults: | ||||||
|  |           'py-2 px-3 text-gray-600 bg-white dark:bg-gray-700 dark:text-gray-200', | ||||||
|         fakeInput: |         fakeInput: | ||||||
|           'bg-transparent absolute left-0 right-0 -bottom-px w-full h-px border-0 p-0 appearance-none outline-none text-transparent', |           'bg-transparent absolute left-0 right-0 -bottom-px w-full h-px border-0 p-0 appearance-none outline-none text-transparent', | ||||||
|         spacer: 'h-9 py-px box-content', |         spacer: 'h-9 py-px box-content', | ||||||
|  | |||||||
| @ -65,7 +65,6 @@ | |||||||
|         rounded-l-md |         rounded-l-md | ||||||
|         bg-gray-50 |         bg-gray-50 | ||||||
|         sm:text-sm |         sm:text-sm | ||||||
|         dark:bg-gray-800 dark:border-gray-600 dark:text-gray-300 |  | ||||||
|       " |       " | ||||||
|     > |     > | ||||||
|       {{ addon }} |       {{ addon }} | ||||||
| @ -83,7 +82,7 @@ | |||||||
|         pointer-events-none |         pointer-events-none | ||||||
|       " |       " | ||||||
|     > |     > | ||||||
|       <span class="text-gray-500 dark:text-white sm:text-sm "> |       <span class="text-gray-500 sm:text-sm"> | ||||||
|         {{ inlineAddon }} |         {{ inlineAddon }} | ||||||
|       </span> |       </span> | ||||||
|     </div> |     </div> | ||||||
| @ -200,7 +199,7 @@ const props = defineProps({ | |||||||
|   defaultInputClass: { |   defaultInputClass: { | ||||||
|     type: String, |     type: String, | ||||||
|     default: |     default: | ||||||
|       'font-base block w-full sm:text-sm border-gray-200 rounded-md text-black  dark:bg-gray-700 dark:border-gray-600 dark:text-white dark:placeholder-gray-500', |       'font-base block w-full sm:text-sm border-gray-200 rounded-md text-black', | ||||||
|   }, |   }, | ||||||
|   iconLeftClass: { |   iconLeftClass: { | ||||||
|     type: String, |     type: String, | ||||||
| @ -251,8 +250,7 @@ const inputAddonClass = computed(() => { | |||||||
|  |  | ||||||
| const inputInvalidClass = computed(() => { | const inputInvalidClass = computed(() => { | ||||||
|   if (props.invalid) { |   if (props.invalid) { | ||||||
|     return 'border-red-500 dark:border-red-500 ring-red-500 dark:ring-red-500 focus:ring-red-500 dark:focus:ring-red-500  focus:border-red-500  dark:focus:border-red-500  ' |     return 'border-red-500 ring-red-500 focus:ring-red-500 focus:border-red-500' | ||||||
|  |  | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   return 'focus:ring-primary-400 focus:border-primary-400' |   return 'focus:ring-primary-400 focus:border-primary-400' | ||||||
| @ -260,7 +258,7 @@ const inputInvalidClass = computed(() => { | |||||||
|  |  | ||||||
| const inputDisabledClass = computed(() => { | const inputDisabledClass = computed(() => { | ||||||
|   if (props.disabled) { |   if (props.disabled) { | ||||||
|     return `border-gray-100 bg-gray-100 !text-gray-400 dark:!text-gray-200   ring-gray-200 focus:ring-gray-200 focus:border-gray-100 dark:opacity-25 ` |     return `border-gray-100 bg-gray-100 !text-gray-400 ring-gray-200 focus:ring-gray-200 focus:border-gray-100` | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   return '' |   return '' | ||||||
|  | |||||||
| @ -44,10 +44,15 @@ module.exports = { | |||||||
|         88: '22rem', |         88: '22rem', | ||||||
|       }, |       }, | ||||||
|       backgroundImage: (theme) => ({ |       backgroundImage: (theme) => ({ | ||||||
|         'multiselect-caret': `url("${svgToDataUri( |         'multiselect-caret-black': `url("${svgToDataUri( | ||||||
|           `<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" viewBox="0 0 20 20" fill="currentColor"> |           `<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" viewBox="0 0 20 20" fill="black"> | ||||||
|             <path fill-rule="evenodd" d="M10 3a1 1 0 01.707.293l3 3a1 1 0 01-1.414 1.414L10 5.414 7.707 7.707a1 1 0 01-1.414-1.414l3-3A1 1 0 0110 3zm-3.707 9.293a1 1 0 011.414 0L10 14.586l2.293-2.293a1 1 0 011.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z" clip-rule="evenodd" /> |             <path fill-rule="evenodd" d="M10 3a1 1 0 01.707.293l3 3a1 1 0 01-1.414 1.414L10 5.414 7.707 7.707a1 1 0 01-1.414-1.414l3-3A1 1 0 0110 3zm-3.707 9.293a1 1 0 011.414 0L10 14.586l2.293-2.293a1 1 0 011.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z" clip-rule="evenodd" /> | ||||||
| </svg>` |           </svg>`, | ||||||
|  |         )}")`, | ||||||
|  |         'multiselect-caret-white': `url("${svgToDataUri( | ||||||
|  |           `<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" viewBox="0 0 20 20" fill="white"> | ||||||
|  |             <path fill-rule="evenodd" d="M10 3a1 1 0 01.707.293l3 3a1 1 0 01-1.414 1.414L10 5.414 7.707 7.707a1 1 0 01-1.414-1.414l3-3A1 1 0 0110 3zm-3.707 9.293a1 1 0 011.414 0L10 14.586l2.293-2.293a1 1 0 011.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z" clip-rule="evenodd" /> | ||||||
|  |           </svg>`, | ||||||
|         )}")`, |         )}")`, | ||||||
|         'multiselect-spinner': `url("${svgToDataUri( |         'multiselect-spinner': `url("${svgToDataUri( | ||||||
|           `<svg viewBox="0 0 512 512" fill="${theme( |           `<svg viewBox="0 0 512 512" fill="${theme( | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user