OOKNET                             [ /  search the index  ]  
──────────────────────────────────────────────────────────────────────────────────────
══════════════════════════════════════════════════════════════════════════════════════
OOKNET   [ /  search  ]  
────────────────────────────────────────────────
════════════════════════════════════════════════
 
 
main @ 242 LINES
 
[ HISTORY ]  [ UP ]
 

{
  lib,
  osConfig,
  ook,
  ...
}: let
  inherit (lib) mkIf;
  inherit (osConfig.ooknet.appearance) fonts;
  inherit (ook) color;
  inherit (osConfig.ooknet.workstation) default;
  cfg = osConfig.ooknet.workstation.programs.firefox;
in {
  config = mkIf (default.browser == "firefox" || cfg.enable) {
    xdg.configFile = {
      "tridactyl/tridactylrc".text = ''

        sanitise tridactyllocal tridactylsync

        colorscheme ooknet

        set searchurls.nix https://sourcegraph.com/search?q=context:global+lang:ni
x %s

        unbind --mode=normal gt

        bind / fillcmdline find
        bind n findnext 1
        bind N findnext -1

        bind gtr open http://192.168.1.210:9091/transmission/web/

        bind gem open https://gmail.com

        bind gjf open http://192.168.1.210:8096

        bindurl next\.duckduckgo\.com ;f hint -Jc  a.result__a
        bindurl next\.duckduckgo\.com ;F hint -Jbc a.result__a

        bindurl www\.google\.com ;f hint -Jc .rc > .yuRUbf > a
        bindurl www\.google\.com ;F hint -Jbc .rc > .yuRUbf > a

        bindurl github\.com/.*/.*/issues ;f hint -Jc a.h4
        bindurl github\.com/.*/.*/issues ;F hint -Jbc a.h4
        bindurl github\.com/.*/.*/commits ;f hint -Jc a.message
        bindurl github\.com/.*/.*/commits ;F hint -Jbc a.messag

        set externalclipboardcmd wl-copy
        set yankto both
      '';

      # based off base16 themes
      # source: <https://github.com/bezmi/base16-tridactyl>
      "tridactyl/themes/ooknet.css".text =
        /*
        css
        */
        ''
          :root {
            --font: ${fonts.monospace.family};
            --bg: #${color.layout.menu};
            --fg: #${color.typography.text};
            --red: #${color.red.base};
            --green: #${color.green.base};
            --blue: #${color.blue.base};
            --yellow: #${color.yellow.base};
            --purple: #${color.purple.base};
            --orange: #${color.orange.base};
            --cyan: #${color.teal.base};
            --comment: #${color.typography.subtext};
            --selectedline: #${color.secondary.base};


            --tridactyl-fg: var(--fg);
            --tridactyl-bg: var(--bg);

            --tridactyl-url-fg: var(--green);
            --tridactyl-url-bg: var(--bg);

            --tridactyl-highlight-box-bg: var(--selectedline);
            --tridactyl-highlight-box-fg: var(--fg);

            --tridactyl-of-fg: var(--fg);
            --tridactyl-of-bg: var(--selectedline);

            --tridactyl-cmdl-fg: var(--bg);
            --tridactyl-cmdl-font-family: var(--selectedline);

            --tridactyl-cmplt-font-family: var(--font);

            --tridactyl-hintspan-font-family: var(--font);
            --tridactyl-hintspan-fg: var(--bg) !important;
            --tridactyl-hintspan-bg: var(--orange) !important;

            --tridactyl-hint-active-fg: none;
            --tridactyl-hint-active-bg: var(--tridactyl-bg);
            --tridactyl-hint-active-outline: var(--green);
            --tridactyl-hint-bg: none;
            --tridactyl-hint-outline: none;
          }

          #tridactyl-colon::before {
            content: "? ";
            font-family: var(--font);
            font-size: 1.5rem;
            color: var(--green);
            display: inline;
            margin-left: 15px;
          }

          #command-line-holder {
            order: 1;
            display: flex;
            justify-content: center;
            align-items: center;
            border: 2px solid var(--tridactyl-fg);
            background: var(--tridactyl-bg);
          }

          #tridactyl-input {
            padding: 1rem;
            color: var(--tridactyl-fg);
            width: 90%;
            font-family: var(--font);
            font-size: 1.5rem;
            line-height: 1.5;
            background: var(--tridactyl-bg);
            padding-left: unset;
            padding: 1rem;
          }


          #completions table {
            font-size: 0.8rem;
            font-weight: 200;
            border-spacing: 0;
            table-layout: fixed;
            padding: 1rem;
            padding-top: 1rem;
            padding-bottom: 1rem;
          }

          #completions > div {
            max-height: calc(20 * var(--option-height));
            min-height: calc(10 * var(--option-height));
          }

          #completions {
            --option-height: 1.4em;
            color: var(--tridactyl-fg);
            background: var(--tridactyl-bg);
            display: inline-block;
            font-size: unset;
            font-weight: 200;
            overflow: hidden;
            width: 100%;
            border-top: unset;
            order: 2;
          }

          #completions .HistoryCompletionSource {
            max-height: unset;
            min-height: unset;
          }

          #completions .HistoryCompletionSource table {
            width: 100%;
            font-size: 9pt;
            border-spacing: 0;
            table-layout: fixed;
          }

          #completions .BmarkCompletionSource {
            max-height: unset;
            min-height: unset;
          }

          #completions table tr td.prefix,
          #completions table tr td.privatewindow,
          #completions table tr td.container,
          #completions table tr td.icon {
            display: none;
          }

          #completions .BufferCompletionSource table {
            width: unset;
            font-size: unset;
            border-spacing: unset;
            table-layout: unset;
          }

          #completions table tr .title {
            width: 50%;
          }

          #completions table tr {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
          }

          #completions .sectionHeader {
            background: unset;
            font-weight: bold;
            border-bottom: unset;
            padding: 1rem !important;
            padding-left: unset;
            padding-bottom: 0.2rem;
          }

          #cmdline_iframe {
            position: fixed !important;
            bottom: unset;
            top: 25% !important;
            left: 10% !important;
            z-index: 2147483647 !important;
            width: 80% !important;
            box-shadow: rgba(0, 0, 0, 0.5) 0px 0px 20px !important;
          }

          .TridactylStatusIndicator {
            position: fixed !important;
            bottom: 0 !important;
            background: var(--tridactyl-bg) !important;
            border: unset !important;
            border: 1px var(--green) solid !important;
            font-size: 12pt !important;
            padding: 0.8ex !important;
          }

          #completions .focused {
            background: var(--green);
            color: var(--bg);
          }

          #completions .focused .url {
            background: var(--green);
            color: var(--bg);
          }
        '';
    };
  };
}

{
  lib,
  osConfig,
  ook,
  ...
}: let
  inherit (lib) mkIf;
  inherit (osConfig.ooknet.appearance) fonts
;
  inherit (ook) color;
  inherit (osConfig.ooknet.workstation) defa
ult;
  cfg = osConfig.ooknet.workstation.programs
.firefox;
in {
  config = mkIf (default.browser == "firefox
" || cfg.enable) {
    xdg.configFile = {
      "tridactyl/tridactylrc".text = ''

        sanitise tridactyllocal tridactylsyn
c

        colorscheme ooknet

        set searchurls.nix https://sourcegra
ph.com/search?q=context:global+lang:nix %s

        unbind --mode=normal gt

        bind / fillcmdline find
        bind n findnext 1
        bind N findnext -1

        bind gtr open http://192.168.1.210:9
091/transmission/web/

        bind gem open https://gmail.com

        bind gjf open http://192.168.1.210:8
096

        bindurl next\.duckduckgo\.com ;f hin
t -Jc  a.result__a
        bindurl next\.duckduckgo\.com ;F hin
t -Jbc a.result__a

        bindurl www\.google\.com ;f hint -Jc
 .rc > .yuRUbf > a
        bindurl www\.google\.com ;F hint -Jb
c .rc > .yuRUbf > a

        bindurl github\.com/.*/.*/issues ;f 
hint -Jc a.h4
        bindurl github\.com/.*/.*/issues ;F 
hint -Jbc a.h4
        bindurl github\.com/.*/.*/commits ;f
 hint -Jc a.message
        bindurl github\.com/.*/.*/commits ;F
 hint -Jbc a.messag

        set externalclipboardcmd wl-copy
        set yankto both
      '';

      # based off base16 themes
      # source: <https://github.com/bezmi/ba
se16-tridactyl>
      "tridactyl/themes/ooknet.css".text =
        /*
        css
        */
        ''
          :root {
            --font: ${fonts.monospace.family
};
            --bg: #${color.layout.menu};
            --fg: #${color.typography.text};
            --red: #${color.red.base};
            --green: #${color.green.base};
            --blue: #${color.blue.base};
            --yellow: #${color.yellow.base};
            --purple: #${color.purple.base};
            --orange: #${color.orange.base};
            --cyan: #${color.teal.base};
            --comment: #${color.typography.s
ubtext};
            --selectedline: #${color.seconda
ry.base};


            --tridactyl-fg: var(--fg);
            --tridactyl-bg: var(--bg);

            --tridactyl-url-fg: var(--green)
;
            --tridactyl-url-bg: var(--bg);

            --tridactyl-highlight-box-bg: va
r(--selectedline);
            --tridactyl-highlight-box-fg: va
r(--fg);

            --tridactyl-of-fg: var(--fg);
            --tridactyl-of-bg: var(--selecte
dline);

            --tridactyl-cmdl-fg: var(--bg);
            --tridactyl-cmdl-font-family: va
r(--selectedline);

            --tridactyl-cmplt-font-family: v
ar(--font);

            --tridactyl-hintspan-font-family
: var(--font);
            --tridactyl-hintspan-fg: var(--b
g) !important;
            --tridactyl-hintspan-bg: var(--o
range) !important;

            --tridactyl-hint-active-fg: none
;
            --tridactyl-hint-active-bg: var(
--tridactyl-bg);
            --tridactyl-hint-active-outline:
 var(--green);
            --tridactyl-hint-bg: none;
            --tridactyl-hint-outline: none;
          }

          #tridactyl-colon::before {
            content: "? ";
            font-family: var(--font);
            font-size: 1.5rem;
            color: var(--green);
            display: inline;
            margin-left: 15px;
          }

          #command-line-holder {
            order: 1;
            display: flex;
            justify-content: center;
            align-items: center;
            border: 2px solid var(--tridacty
l-fg);
            background: var(--tridactyl-bg);
          }

          #tridactyl-input {
            padding: 1rem;
            color: var(--tridactyl-fg);
            width: 90%;
            font-family: var(--font);
            font-size: 1.5rem;
            line-height: 1.5;
            background: var(--tridactyl-bg);
            padding-left: unset;
            padding: 1rem;
          }


          #completions table {
            font-size: 0.8rem;
            font-weight: 200;
            border-spacing: 0;
            table-layout: fixed;
            padding: 1rem;
            padding-top: 1rem;
            padding-bottom: 1rem;
          }

          #completions > div {
            max-height: calc(20 * var(--opti
on-height));
            min-height: calc(10 * var(--opti
on-height));
          }

          #completions {
            --option-height: 1.4em;
            color: var(--tridactyl-fg);
            background: var(--tridactyl-bg);
            display: inline-block;
            font-size: unset;
            font-weight: 200;
            overflow: hidden;
            width: 100%;
            border-top: unset;
            order: 2;
          }

          #completions .HistoryCompletionSou
rce {
            max-height: unset;
            min-height: unset;
          }

          #completions .HistoryCompletionSou
rce table {
            width: 100%;
            font-size: 9pt;
            border-spacing: 0;
            table-layout: fixed;
          }

          #completions .BmarkCompletionSourc
e {
            max-height: unset;
            min-height: unset;
          }

          #completions table tr td.prefix,
          #completions table tr td.privatewi
ndow,
          #completions table tr td.container
,
          #completions table tr td.icon {
            display: none;
          }

          #completions .BufferCompletionSour
ce table {
            width: unset;
            font-size: unset;
            border-spacing: unset;
            table-layout: unset;
          }

          #completions table tr .title {
            width: 50%;
          }

          #completions table tr {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
          }

          #completions .sectionHeader {
            background: unset;
            font-weight: bold;
            border-bottom: unset;
            padding: 1rem !important;
            padding-left: unset;
            padding-bottom: 0.2rem;
          }

          #cmdline_iframe {
            position: fixed !important;
            bottom: unset;
            top: 25% !important;
            left: 10% !important;
            z-index: 2147483647 !important;
            width: 80% !important;
            box-shadow: rgba(0, 0, 0, 0.5) 0
px 0px 20px !important;
          }

          .TridactylStatusIndicator {
            position: fixed !important;
            bottom: 0 !important;
            background: var(--tridactyl-bg) 
!important;
            border: unset !important;
            border: 1px var(--green) solid !
important;
            font-size: 12pt !important;
            padding: 0.8ex !important;
          }

          #completions .focused {
            background: var(--green);
            color: var(--bg);
          }

          #completions .focused .url {
            background: var(--green);
            color: var(--bg);
          }
        '';
    };
  };
}
 
──────────────────────────────────────────────────────────────────────────────────────
OOKNET
────────────────────────────────────────────────
OOKNET