diff --git a/README.md b/README.md index 975114cc..6b914c7f 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ The objective is to have a self-hosted place to keep useful links in one place, * 🏷 Set multiple tags to each link. -* 🗂 Assign each link to a list where we can further group links. +* 🗂 Assign each link to a collection where we can further group links. **Also take a look at our planned features in the [project roadmap section](https://github.com/Daniel31x13/link-warden/wiki#project-roadmap).** diff --git a/src/App.js b/src/App.js index ec93a269..b6e2f5fa 100644 --- a/src/App.js +++ b/src/App.js @@ -7,12 +7,12 @@ import Filters from "./componets/Filters"; import sortList from "./modules/sortList"; import filter from "./modules/filterData"; import concatTags from "./modules/concatTags"; -import concatLists from "./modules/concatLists"; +import concatCollections from "./modules/concatCollections"; import NoResults from "./componets/NoResults"; import Loader from "./componets/Loader"; import SideBar from "./componets/SideBar"; import Tags from "./routes/Tags.js"; -import Lists from "./routes/Lists.js"; +import Collections from "./routes/Collections.js"; import { Route, Routes } from "react-router-dom"; function App() { @@ -96,7 +96,7 @@ function App() {
@@ -154,7 +154,7 @@ function App() { reFetch={fetchData} lightMode={lightMode} tags={() => concatTags(data)} - lists={() => concatLists(data)} + collections={() => concatCollections(data)} /> ) : null} @@ -173,7 +173,7 @@ function App() { SetLoader={SetLoader} data={filteredData} tags={concatTags(data)} - lists={concatLists(data)} + collections={concatCollections(data)} reFetch={fetchData} />
@@ -188,21 +188,21 @@ function App() { SetLoader={SetLoader} data={filteredData} tags={concatTags(data)} - lists={concatLists(data)} + collections={concatCollections(data)} reFetch={fetchData} /> } /> } diff --git a/src/componets/AddItem.js b/src/componets/AddItem.js index f42bac82..e17ac164 100644 --- a/src/componets/AddItem.js +++ b/src/componets/AddItem.js @@ -2,17 +2,24 @@ import { useState } from "react"; import "../styles/SendItem.css"; import TagSelection from "./TagSelection"; import addItem from "../modules/send"; -import ListSelection from "./ListSelection"; +import CollectionSelection from "./CollectionSelection"; -const AddItem = ({ onExit, reFetch, tags, lists, SetLoader, lightMode }) => { +const AddItem = ({ + onExit, + reFetch, + tags, + collections, + SetLoader, + lightMode, +}) => { const [name, setName] = useState(""), [link, setLink] = useState(""), [tag, setTag] = useState([]), - [list, setList] = useState([]); + [collection, setCollection] = useState("Unsorted"); function newItem() { SetLoader(true); - addItem(name, link, tag, list, reFetch, onExit, SetLoader, "POST"); + addItem(name, link, tag, collection, reFetch, onExit, SetLoader, "POST"); } function SetName(e) { @@ -27,8 +34,8 @@ const AddItem = ({ onExit, reFetch, tags, lists, SetLoader, lightMode }) => { setTag(value.map((e) => e.value.toLowerCase())); } - function SetList(value) { - setList(value.value); + function SetCollection(value) { + setCollection(value.value); } function abort(e) { @@ -67,11 +74,11 @@ const AddItem = ({ onExit, reFetch, tags, lists, SetLoader, lightMode }) => {

- List: (Optional) + Collections: (Optional)

-