mirror of
https://github.com/streetwriters/notesnook.git
synced 2026-02-24 04:00:59 +01:00
web: remove unneeded modules
This commit is contained in:
committed by
Abdullah Atta
parent
9291711036
commit
0a02431f6a
@@ -1,31 +0,0 @@
|
||||
import fetch from "node-fetch";
|
||||
import fs from "fs/promises";
|
||||
|
||||
async function getMilestones() {
|
||||
const url = `https://api.github.com/repos/streetwriters/notesnook/milestones?state=closed`;
|
||||
const response = await fetch(url);
|
||||
if (response.ok) return await response.json();
|
||||
}
|
||||
|
||||
async function getIssues(milestone) {
|
||||
const url = `https://api.github.com/repos/streetwriters/notesnook/issues?milestone=${milestone}&state=closed`;
|
||||
const response = await fetch(url);
|
||||
if (response.ok) return await response.json();
|
||||
}
|
||||
|
||||
(async function main() {
|
||||
const milestone = (await getMilestones())
|
||||
.sort((a, b) => a.number - b.number)
|
||||
.pop();
|
||||
console.log("Generating changelog for version", milestone.title);
|
||||
const issues = await getIssues(milestone.number);
|
||||
|
||||
await fs.writeFile(
|
||||
`changelog-${milestone.title}.md`,
|
||||
issues
|
||||
.map((issue, index) => {
|
||||
return `${index + 1}. ${issue.title} (#${issue.number})`;
|
||||
})
|
||||
.join("\n")
|
||||
);
|
||||
})();
|
||||
@@ -1,41 +0,0 @@
|
||||
/*
|
||||
This file is part of the Notesnook project (https://notesnook.com/)
|
||||
|
||||
Copyright (C) 2023 Streetwriters (Private) Limited
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { Flex, Text } from "@theme-ui/components";
|
||||
import { Loading } from "../icons";
|
||||
import { strings } from "@notesnook/intl";
|
||||
|
||||
function EditorLoading({ text }: { text?: string }) {
|
||||
return (
|
||||
<Flex
|
||||
sx={{
|
||||
flex: 1,
|
||||
flexDirection: "column",
|
||||
alignItems: "center",
|
||||
justifyContent: "center"
|
||||
}}
|
||||
>
|
||||
<Loading color="accent" sx={{ mt: 2 }} />
|
||||
<Text variant="body" mt={2} sx={{ textAlign: "center" }}>
|
||||
{text || strings.loadingEditor()}
|
||||
</Text>
|
||||
</Flex>
|
||||
);
|
||||
}
|
||||
export default EditorLoading;
|
||||
@@ -1,20 +0,0 @@
|
||||
/*
|
||||
This file is part of the Notesnook project (https://notesnook.com/)
|
||||
|
||||
Copyright (C) 2023 Streetwriters (Private) Limited
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
console.log("loading theme");
|
||||
@@ -1,29 +0,0 @@
|
||||
/*
|
||||
This file is part of the Notesnook project (https://notesnook.com/)
|
||||
|
||||
Copyright (C) 2023 Streetwriters (Private) Limited
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
function isMobile(): boolean {
|
||||
return window.matchMedia("(max-width: 480px)").matches;
|
||||
}
|
||||
|
||||
function isTablet(): boolean {
|
||||
return window.matchMedia("(min-width: 480px) and (max-width: 1000px)")
|
||||
.matches;
|
||||
}
|
||||
|
||||
export { isMobile, isTablet };
|
||||
Reference in New Issue
Block a user