/*
 * Copyright 2024 Palantir Technologies, Inc. All rights reserved.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

import * as React from "react";
import type { SVGIconProps } from "../../svgIconProps";
import { IconSize } from "../../iconTypes";
import { SVGIconContainer } from "../../svgIconContainer";

/** Path data for the 16px grid; matches {@link generate-icon-paths.mjs} / `<Icon />` from core. */
const PATHS_16 = ["M12.444 6C10.544 6 9 7.494 9 9.331 9 11.175 12.444 16 12.444 16s3.443-4.825 3.443-6.669C15.881 7.494 14.345 6 12.445 6m.056 5a1.5 1.5 0 1 1 .001-3.001A1.5 1.5 0 0 1 12.5 11M0 6c0-3.315 2.685-6 6-6a6 6 0 0 1 5.923 5.036 4.6 4.6 0 0 0-1.454.433A4.505 4.505 0 0 0 6 1.5 4.504 4.504 0 0 0 1.5 6a4.504 4.504 0 0 0 6.58 3.99c.093.425.265.913.488 1.435A6 6 0 0 1 6 12c-3.315 0-6-2.685-6-6m6.75-2.25v1.943l1.283 1.275a.752.752 0 0 1-1.065 1.065l-1.5-1.5A.75.75 0 0 1 5.25 6V3.75c0-.412.338-.75.75-.75s.75.338.75.75"] as readonly string[];

/** Path data for the 20px grid; matches {@link generate-icon-paths.mjs} / `<Icon />` from core. */
const PATHS_20 = ["M15.555 7c-2.375 0-4.305 1.867-4.305 4.164 0 2.305 4.305 8.836 4.305 8.836s4.304-6.531 4.304-8.836C19.852 8.867 17.93 7 15.555 7m0 6.25a1.954 1.954 0 1 1 .001-3.908 1.954 1.954 0 0 1-.001 3.908M0 7.5C0 3.356 3.356 0 7.5 0a7.5 7.5 0 0 1 7.359 6.044 5.4 5.4 0 0 0-1.804.566A5.63 5.63 0 0 0 7.5 1.875 5.63 5.63 0 0 0 1.875 7.5 5.63 5.63 0 0 0 7.5 13.125c1.07 0 2.072-.3 2.924-.82.14.525.352 1.078.58 1.608l.078.178A7.5 7.5 0 0 1 7.5 15 7.5 7.5 0 0 1 0 7.5m8.438-3.563v3.179l1.603 1.593A.94.94 0 0 1 8.71 10.04L6.833 8.167a.94.94 0 0 1-.271-.666V3.937A.94.94 0 0 1 7.5 3a.94.94 0 0 1 .938.937"] as readonly string[];

export const Geotime: React.FC<SVGIconProps> = React.forwardRef<any, SVGIconProps>((props, ref) => {
    const isLarge = (props.size ?? IconSize.STANDARD) >= IconSize.LARGE;
    const paths = isLarge ? PATHS_20 : PATHS_16;
    return (
        <SVGIconContainer iconName="geotime" ref={ref} {...props}>
            {paths.map((d, i) => (
                <path key={i} d={d} fillRule="evenodd" />
            ))}
        </SVGIconContainer>
    );
});
Geotime.displayName = `Blueprint6.Icon.Geotime`;
export default Geotime;
