Giter Site home page Giter Site logo

mrjones2014 / lighthaus.nvim Goto Github PK

View Code? Open in Web Editor NEW
64.0 4.0 5.0 1.81 MB

A Lua implementation of lighthaus-theme/vim-lighthaus

License: MIT License

Lua 99.55% Vim Script 0.45%
neovim neovim-plugin neovim-theme lua lighthaus-theme lighthaus hacktoberfest nvim lsp nvim-cmp

lighthaus.nvim's Issues

Add Alacritty theme

Alacritty is probably just as popular as Kitty so we should offer an Alacritty theme as well.

Error on load (init.lua:129)

Thanks for making this, went to try it out but get this error:

E5108: Error executing lua ...te/pack/paqs/start/lighthaus.nvim/lua/lighthaus/init.lua:129: attempt to index local 'options' (a ni
l value)

Think I have done everything accoding to readme correctly!

`nvim-treesitter` highlight missing in some diff files

I found this issue with gitcommit and diff files.

my lighthaus and treesitter config:

require("nvim-treesitter.configs").setup {
	auto_install = true,
	highlight = {
		enable = true,
		additional_vim_regex_highlighting = false,
	},
}

require("lighthaus").setup {
	bg_dark = true,
	colors = {
		-- black = '#0E0E10',
		-- black = '#1e1d23',
		black = "#111111",
		fg_nc_statusline = "#888888",
		red = "#FC2929",
		red2 = "#FF5050",
		blue = "#1D918B",
		blue2 = "#47A8A1",
		blue3 = "#0db9d7",
		hl_yellow = "#FFFF00",
		hl_orange = "#FF4D00",
		hl_bg = "#fff",
		hl_bg_dark = "#282c34",
		gutter_bg = "#282c34",
		non_text = "#373C45",
		lsp_error = "#db4b4b",
		lsp_warning = "#e0af68",
		lsp_information = "#0db9d7",
		lsp_hint = "#10B981",
		-- bg = 'Red'
	},
	lsp_underline_style = "undercurl",
}

some examples:

lightaus.nvim:
Screenshot 2023-01-07 at 12 49 02

catppuccin:
Screenshot 2023-01-07 at 12 49 15

the diff file:

diff --git a/apps/dashboard-v2/shared/containers/ScheduledJobsPage/ScheduledJobsTableAdvancedSearch.tsx b/apps/dashboard-v2/shared/containers/ScheduledJobsPage/ScheduledJobsTableAdvancedSearch.tsx
index a83ecd575..33a4a4e16 100644
--- a/apps/dashboard-v2/shared/containers/ScheduledJobsPage/ScheduledJobsTableAdvancedSearch.tsx
+++ b/apps/dashboard-v2/shared/containers/ScheduledJobsPage/ScheduledJobsTableAdvancedSearch.tsx
@@ -1,5 +1,5 @@
 import { useMemo } from "react";
-import { Column, TableState, CellValue, Row } from "react-table";
+import { TableState, CellValue, Row } from "react-table";
 import { useHistory } from "react-router-dom";
 import { DateTime } from "luxon";
 
@@ -44,137 +44,133 @@ const ScheduledJobsTableAvancedTable = ({
   const { push } = useHistory();
 
   const columns = useMemo(
-    () =>
-      [
-        {
-          id: "jobDate",
-          Header: datetimeColumn.name,
-          accessor: (originalRow) => new Date(getDate(originalRow)),
-          Cell: ({ value, row: { original } }: CellValue) => {
-            const date = DateTime.fromJSDate(value).toFormat("dd/MM/yyyy");
-            return <span id={`jobDate-${original.id}`}>{date}</span>;
-          },
-          sortType: "datetime",
+    () => [
+      {
+        id: "jobDate",
+        Header: datetimeColumn.name,
+        accessor: (originalRow: Job) => new Date(getDate(originalRow)),
+        Cell: ({ value, row: { original } }: CellValue) => {
+          const date = DateTime.fromJSDate(value).toFormat("dd/MM/yyyy");
+          return <span id={`jobDate-${original.id}`}>{date}</span>;
         },
-        {
-          id: "deliveryId",
-          Header: (
-            <FormattedMessage
-              id="PackageTable.package_id"
-              defaultMessage="Package ID"
-            />
-          ),
-          accessor: (originalRow) => originalRow.deliveries,
-          Cell: ({ value }: CellValue) =>
-            value.map((delivery: Delivery, index: number) => (
-              <div
-                id={`packageId-${delivery.id}}`}
-                key={delivery.id}
-                className={cx({
-                  [layoutStyles.mbs]: index !== value.length - 1,
-                })}
-              >
-                <CopyButton
-                  id={`copyButton-${delivery.id}`}
-                  text={delivery.id as string}
-                />
-              </div>
-            )),
-          disableSortBy: true,
-          minWidth: 160,
-        },
-        {
-          id: "clientReference",
-          Header: clientReferenceColumn.name,
-          accessor: (originalRow) => originalRow.deliveries,
-          disableSortBy: true,
-          Cell: ({ value }: CellValue) =>
-            value.map((delivery: Delivery, index: number) => (
-              <div
-                id={`clientReference-${delivery.id}}`}
-                key={delivery.id}
-                className={cx({
-                  [layoutStyles.mbm]: index !== value.length - 1,
-                })}
-              >
-                {delivery.clientReference ? (
-                  <span>{delivery.clientReference}</span>
-                ) : (
-                  <FormattedMessage id="jobTable.none" defaultMessage="None" />
-                )}
-              </div>
-            )),
-        },
-        {
-          id: "PU Time",
-          Header: (
-            <FormattedMessage
-              id="jobTable.pickupTime"
-              defaultMessage="Pick-up time"
-            />
-          ),
-          accessor: (originalRow) => originalRow,
-          disableSortBy: true,
-          Cell: ({ value }: CellValue) => (
-            <p id={`pickupAtTime-${value.id}`}>
-              <FormattedTime value={value.pickupAt} />
-            </p>
-          ),
-        },
-        {
-          id: "PU",
-          Header: pickUpColumn.name,
-          accessor: (originalRow) => originalRow.deliveries,
-          disableSortBy: true,
-          width: 300,
-          Cell: ({ value }: CellValue) =>
-            value.map((delivery: Delivery, index: number) => (
-              <div
-                id={`pickUpAddress-${delivery.id}}`}
-                key={delivery.id}
-                className={cx({
-                  [layoutStyles.mbm]: index !== value.length - 1,
-                })}
-              >
-                {delivery.pickup.address && (
-                  <Address address={delivery.dropoff.address}>
-                    {(m) => <span className={styles.placeAddress}>{m}</span>}
-                  </Address>
-                )}
-              </div>
-            )),
-        },
-        {
-          id: "DO",
-          Header: dropOffColumn.name,
-          accessor: (originalRow) => originalRow.deliveries,
-          disableSortBy: true,
-          width: 300,
-          Cell: ({ value }: CellValue) =>
-            value.map((delivery: Delivery, index: number) => (
-              <div
-                id={`dropOffAddress-${delivery.id}}`}
-                key={delivery.id}
-                className={cx({
-                  [layoutStyles.mbm]: index !== value.length - 1,
-                })}
-              >
-                {delivery.dropoff.address && (
-                  <Address address={delivery.dropoff.address}>
-                    {(m) => <span className={styles.placeAddress}>{m}</span>}
-                  </Address>
-                )}
-              </div>
-            )),
-        },
-        {
-          id: "action",
-          accessor: (originalRow) => originalRow,
-          disableSortBy: true,
-          Cell: ({ value }: CellValue) =>
-            cancelColumn.renderer(value, { onJobCancelClick }),
-        },
-      ] as Column<Job>[],
+        sortType: "datetime",
+      },
+      {
+        id: "deliveryId",
+        Header: (
+          <FormattedMessage
+            id="PackageTable.package_id"
+            defaultMessage="Package ID"
+          />
+        ),
+        accessor: (originalRow: Job) => originalRow.deliveries,
+        Cell: ({ value }: CellValue) =>
+          value.map((delivery: Delivery, index: number) => (
+            <div
+              id={`packageId-${delivery.id}}`}
+              key={delivery.id}
+              className={cx({
+                [layoutStyles.mbs]: index !== value.length - 1,
+              })}
+            >
+              <CopyButton id={`copyButton-${delivery.id}`} text={delivery.id} />
+            </div>
+          )),
+        disableSortBy: true,
+        minWidth: 160,
+      },
+      {
+        id: "clientReference",
+        Header: clientReferenceColumn.name,
+        accessor: (originalRow: Job) => originalRow.deliveries,
+        disableSortBy: true,
+        Cell: ({ value }: CellValue) =>
+          value.map((delivery: Delivery, index: number) => (
+            <div
+              id={`clientReference-${delivery.id}}`}
+              key={delivery.id}
+              className={cx({
+                [layoutStyles.mbm]: index !== value.length - 1,
+              })}
+            >
+              {delivery.clientReference ? (
+                <span>{delivery.clientReference}</span>
+              ) : (
+                <FormattedMessage id="jobTable.none" defaultMessage="None" />
+              )}
+            </div>
+          )),
+      },
+      {
+        id: "PU Time",
+        Header: (
+          <FormattedMessage
+            id="jobTable.pickupTime"
+            defaultMessage="Pick-up time"
+          />
+        ),
+        accessor: (originalRow: Job) => originalRow,
+        disableSortBy: true,
+        Cell: ({ value }: CellValue) => (
+          <p id={`pickupAtTime-${value.id}`}>
+            <FormattedTime value={value.pickupAt} />
+          </p>
+        ),
+      },
+      {
+        id: "PU",
+        Header: pickUpColumn.name,
+        accessor: (originalRow: Job) => originalRow.deliveries,
+        disableSortBy: true,
+        width: 300,
+        Cell: ({ value }: CellValue) =>
+          value.map((delivery: Delivery, index: number) => (
+            <div
+              id={`pickUpAddress-${delivery.id}}`}
+              key={delivery.id}
+              className={cx({
+                [layoutStyles.mbm]: index !== value.length - 1,
+              })}
+            >
+              {delivery.pickup.address && (
+                <Address address={delivery.dropoff.address}>
+                  {(m) => <span className={styles.placeAddress}>{m}</span>}
+                </Address>
+              )}
+            </div>
+          )),
+      },
+      {
+        id: "DO",
+        Header: dropOffColumn.name,
+        accessor: (originalRow: Job) => originalRow.deliveries,
+        disableSortBy: true,
+        width: 300,
+        Cell: ({ value }: CellValue) =>
+          value.map((delivery: Delivery, index: number) => (
+            <div
+              id={`dropOffAddress-${delivery.id}}`}
+              key={delivery.id}
+              className={cx({
+                [layoutStyles.mbm]: index !== value.length - 1,
+              })}
+            >
+              {delivery.dropoff.address && (
+                <Address address={delivery.dropoff.address}>
+                  {(m) => <span className={styles.placeAddress}>{m}</span>}
+                </Address>
+              )}
+            </div>
+          )),
+      },
+      {
+        id: "action",
+        accessor: (originalRow: Job) => originalRow,
+        disableSortBy: true,
+        Cell: ({ value }: CellValue) =>
+          cancelColumn.renderer(value, { onJobCancelClick }),
+      },
+    ],
     [onJobCancelClick]
   );
 
@@ -185,7 +181,7 @@ const ScheduledJobsTableAvancedTable = ({
           id: "jobDate",
         },
       ],
-    } as Partial<TableState<Job>>;
+    };
   }, []);
 
   const handleOnClick = ({ original: job }: Row<Job>) => {
diff --git a/packages/stuart-ui/CopyButton/index.tsx b/packages/stuart-ui/CopyButton/index.tsx
index 3678c189d..d7f5e86c8 100644
--- a/packages/stuart-ui/CopyButton/index.tsx
+++ b/packages/stuart-ui/CopyButton/index.tsx
@@ -5,7 +5,7 @@ import copyToClipboard from "stuart-libs/copyToClipboard";
 import styles from "./CopyButton.scss";
 
 interface CopyButtonProps {
-  text: string;
+  text: string | number;
   label?: string;
   className?: string;
   id?: string;

`colorcolumn` on top of plain text

I tried loading the settings before and after the plugin loads with not effect.

lightbug
Here is the same line with visual lne to highlight the missing text:
lightbug 2

My lighthaus.nvim setup:

require("lighthaus").setup({
	bg_dark = vim.env.SYS_THEME == "dark" and true or false,
	colors = {
		black = "#111111",
		fg_nc_statusline = "#888888",
	},
	lsp_underline_style = "undercurl",
})
-- maybe this command it's the cause ?
vim.cmd("highlight ColorColumn ctermbg=0 guibg=#111111")

On my config I have vim.wo.colorcolumn = "80" too.

version: NVIM v0.7.0-dev

Missing cursorline highlight?

Hey! Great work with the theme, I like it :) I'd just consider adding an highlight for the cursorline, as there is none at the moment.

Keep up the great work!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.