Eject from preact-cli
This commit is contained in:
@ -1,16 +1,10 @@
|
||||
import { FunctionalComponent, h } from "preact";
|
||||
import { Route, Router, RouterOnChangeArgs } from "preact-router";
|
||||
|
||||
import Home from "../routes/home";
|
||||
import Project from "../routes/project";
|
||||
import NotFoundPage from '../routes/notfound';
|
||||
import Header from "./header";
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
if ((module as any).hot) {
|
||||
// tslint:disable-next-line:no-var-requires
|
||||
require("preact/debug");
|
||||
}
|
||||
import Home from "../routes/home/index";
|
||||
import Project from "../routes/project/index";
|
||||
import NotFoundPage from '../routes/notfound/index';
|
||||
import Header from "./header/index";
|
||||
|
||||
const App: FunctionalComponent = () => {
|
||||
let currentUrl: string;
|
||||
|
@ -1,6 +1,5 @@
|
||||
import { FunctionalComponent, h, Component, ComponentChild, Fragment } from "preact";
|
||||
import { Link } from "preact-router/match";
|
||||
import * as style from "./style.css";
|
||||
import * as style from "./style.module.css";
|
||||
import { useState, useEffect } from "preact/hooks";
|
||||
|
||||
export interface EditableTextProps {
|
||||
|
3
src/components/editable-text/style.css.d.ts
vendored
3
src/components/editable-text/style.css.d.ts
vendored
@ -1,3 +0,0 @@
|
||||
// This file is automatically generated from your CSS. Any edits will be overwritten.
|
||||
export const editableText: string;
|
||||
export const editIcon: string;
|
13
src/components/editable-text/style.module.css.d.ts
vendored
Normal file
13
src/components/editable-text/style.module.css.d.ts
vendored
Normal file
@ -0,0 +1,13 @@
|
||||
declare namespace StyleModuleCssModule {
|
||||
export interface IStyleModuleCss {
|
||||
editIcon: string;
|
||||
editableText: string;
|
||||
}
|
||||
}
|
||||
|
||||
declare const StyleModuleCssModule: StyleModuleCssModule.IStyleModuleCss & {
|
||||
/** WARNING: Only available when `css-loader` is used without `style-loader` or `mini-css-extract-plugin` */
|
||||
locals: StyleModuleCssModule.IStyleModuleCss;
|
||||
};
|
||||
|
||||
export = StyleModuleCssModule;
|
@ -1,5 +1,8 @@
|
||||
import ProjectTimeUnit from "./project-time-unit";
|
||||
import { defaults, getRoundUpEstimations } from "../models/params";
|
||||
import { Project } from "../models/project";
|
||||
import { FunctionalComponent, Fragment, h } from "preact";
|
||||
import { Estimation } from "../hooks/use-project-estimations";
|
||||
|
||||
export interface EstimationRangeProps {
|
||||
project: Project,
|
||||
@ -9,8 +12,8 @@ export interface EstimationRangeProps {
|
||||
|
||||
export const EstimationRange: FunctionalComponent<EstimationRangeProps> = ({ project, estimation, sdFactor }) => {
|
||||
const roundUp = getRoundUpEstimations(project);
|
||||
let e = roundUp ? Math.ceil(estimation.e) : estimation.e;
|
||||
let sd = roundUp ? Math.ceil(estimation.sd * sdFactor) : (estimation.sd * sdFactor);
|
||||
let e: number|string = roundUp ? Math.ceil(estimation.e) : estimation.e;
|
||||
let sd: number|string = roundUp ? Math.ceil(estimation.sd * sdFactor) : (estimation.sd * sdFactor);
|
||||
const max = e+sd;
|
||||
const min = Math.max(e-sd, 0);
|
||||
if (!roundUp) {
|
||||
|
@ -1,6 +1,5 @@
|
||||
import { FunctionalComponent, h } from "preact";
|
||||
import { Link } from "preact-router/match";
|
||||
import * as style from "./style.css";
|
||||
import style from "./style.module.css";
|
||||
|
||||
export interface HeaderProps {
|
||||
class?: string
|
||||
@ -8,7 +7,7 @@ export interface HeaderProps {
|
||||
|
||||
const Header: FunctionalComponent<HeaderProps> = ({ ...props}) => {
|
||||
return (
|
||||
<div class={`container ${props.class ? props.class : ''}`}>
|
||||
<div class={`container ${style.header} ${props.class ? props.class : ''}`}>
|
||||
<div class="columns">
|
||||
<div class="column">
|
||||
<nav class="navbar" role="navigation" aria-label="main navigation">
|
||||
|
3
src/components/header/style.css.d.ts
vendored
3
src/components/header/style.css.d.ts
vendored
@ -1,3 +0,0 @@
|
||||
// This file is automatically generated from your CSS. Any edits will be overwritten.
|
||||
export const header: string;
|
||||
export const active: string;
|
3
src/components/header/style.module.css
Normal file
3
src/components/header/style.module.css
Normal file
@ -0,0 +1,3 @@
|
||||
.header {
|
||||
display: inherit;
|
||||
}
|
12
src/components/header/style.module.css.d.ts
vendored
Normal file
12
src/components/header/style.module.css.d.ts
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
declare namespace StyleModuleCssModule {
|
||||
export interface IStyleModuleCss {
|
||||
header: string;
|
||||
}
|
||||
}
|
||||
|
||||
declare const StyleModuleCssModule: StyleModuleCssModule.IStyleModuleCss & {
|
||||
/** WARNING: Only available when `css-loader` is used without `style-loader` or `mini-css-extract-plugin` */
|
||||
locals: StyleModuleCssModule.IStyleModuleCss;
|
||||
};
|
||||
|
||||
export = StyleModuleCssModule;
|
@ -1,5 +1,5 @@
|
||||
import { FunctionalComponent, h, ComponentChild } from "preact";
|
||||
import * as style from "./style.css";
|
||||
import style from "./style.module.css";
|
||||
import { useState } from "preact/hooks";
|
||||
|
||||
export interface TabItem {
|
||||
|
3
src/components/tabs/style.css.d.ts
vendored
3
src/components/tabs/style.css.d.ts
vendored
@ -1,3 +0,0 @@
|
||||
// This file is automatically generated from your CSS. Any edits will be overwritten.
|
||||
export const tabs: string;
|
||||
export const tabContent: string;
|
13
src/components/tabs/style.module.css.d.ts
vendored
Normal file
13
src/components/tabs/style.module.css.d.ts
vendored
Normal file
@ -0,0 +1,13 @@
|
||||
declare namespace StyleModuleCssModule {
|
||||
export interface IStyleModuleCss {
|
||||
tabContent: string;
|
||||
tabs: string;
|
||||
}
|
||||
}
|
||||
|
||||
declare const StyleModuleCssModule: StyleModuleCssModule.IStyleModuleCss & {
|
||||
/** WARNING: Only available when `css-loader` is used without `style-loader` or `mini-css-extract-plugin` */
|
||||
locals: StyleModuleCssModule.IStyleModuleCss;
|
||||
};
|
||||
|
||||
export = StyleModuleCssModule;
|
Reference in New Issue
Block a user