This file contains hidden or 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
| import { createCalendar } from '@internationalized/date'; | |
| import { useRef } from 'react'; | |
| import { | |
| DateValue, | |
| useDatePicker, | |
| AriaDatePickerProps, | |
| useDateField, | |
| useDateSegment, | |
| } from 'react-aria'; | |
| import { |
This file contains hidden or 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
| import { faChevronDown, faChevronUp } from '@fortawesome/free-solid-svg-icons'; | |
| import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; | |
| import classNames from 'classnames'; | |
| import { useSelect } from 'downshift'; | |
| import { DropdownProps } from 'lib/types/dropdown'; | |
| import { forwardRef } from 'react'; | |
| export const Dropdown = forwardRef<HTMLButtonElement, DropdownProps<string>>( | |
| ({ onChange, error, label, items, initialSelectedItem }, ref) => { | |
| const { |
This file contains hidden or 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
| const menu = [ | |
| { name: 'Item 1' }, | |
| { name: 'Item 2' }, | |
| { name: 'Item 3' }, | |
| { name: 'Item 4' }, | |
| { name: 'Item 5' }, | |
| { name: 'Item 6' }, | |
| { name: 'Item 7' }, | |
| { name: 'Item 8' }, | |
| { name: 'Item 9' }, |
This file contains hidden or 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
| update public."User" | |
| set "isVerified" = true | |
| where "id" = ( | |
| select | |
| u."id" | |
| from | |
| public."User" as u | |
| join public."Tenant" as t on t."id"=u."tenantId" | |
| join public."TenantMeta" as tm on t."id"=tm."tenantId" and tm."token" = '') |
This file contains hidden or 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
| import Link from "next/link"; | |
| import { useRouter } from "next/router"; | |
| import { useEffect, ChangeEvent, MouseEvent } from "react"; | |
| import { useState } from "react"; | |
| type TState = { | |
| name?: string | string[]; | |
| temperature?: string | string[]; | |
| }; |
This file contains hidden or 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
| import { IsString } from 'class-validator'; | |
| export class CreateCoffeeDto { | |
| @IsString() | |
| readonly name: string; | |
| @IsString() | |
| readonly brand: string; | |
| @IsString({ each: true }) |
This file contains hidden or 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
| import React, {FC, useState} from 'react'; | |
| import ReactDOM from 'react-dom'; | |
| import './index.css'; | |
| const someErrorsComingFromAnExpressAPI = { | |
| username: [ | |
| 'Username required', | |
| 'Username must be 3 characters or more', | |
| 'Another error for the username', | |
| ], |
This file contains hidden or 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
| import React, {useReducer} from 'react'; | |
| import {Button} from './components/common/Button'; | |
| import {ErrorLabel} from './components/common/ErrorLabel'; | |
| import {InputField} from './components/common/InputField'; | |
| import {driverReducer} from './reducers/driverReducer'; | |
| import {create, driverEndpoint} from './utils/request'; | |
| export const App = () => { | |
| const [state, dispatch] = useReducer(driverReducer, { | |
| username: '', |