Sonia Appasamy 5f40b8a0bc scripts/check_license_headers: enforce license on ts/tsx files
Enforcing inclusion of our OSS license at the top of .ts and .tsx
files. Also updates any relevant files in the repo that were
previously missing the license comment. An additional `@license`
comment is added to client/web/src/index.tsx to preserve the
license in generated Javascript.

Updates 

Signed-off-by: Sonia Appasamy <sonia@tailscale.com>
2023-11-28 13:57:09 -05:00

33 lines
652 B
TypeScript

// Copyright (c) Tailscale Inc & AUTHORS
// SPDX-License-Identifier: BSD-3-Clause
import cx from "classnames"
import React, { HTMLAttributes } from "react"
type Props = {
className?: string
size: "sm" | "md"
} & HTMLAttributes<HTMLDivElement>
export default function Spinner(props: Props) {
const { className, size, ...rest } = props
return (
<div
className={cx(
"spinner inline-block rounded-full align-middle",
{
"border-2 w-4 h-4": size === "sm",
"border-4 w-8 h-8": size === "md",
},
className
)}
{...rest}
/>
)
}
Spinner.defaultProps = {
size: "md",
}