Radish alpha
r
Radicle web interface
Radicle
Git (anonymous pull)
Log in to clone via SSH
Update .eslintignore and run eslint
Alexis Sellier committed 4 years ago
commit 964e69a86737212697aef56d6a2a5f6c161a4421
parent 7a130baa2406921c8c49dbec682696e8db364e26
12 files changed +18 -15
modified .eslintignore
@@ -1 +1,5 @@
-
node_modules

\ No newline at end of file
+
node_modules
+
build
+
public
+
snowpack.config.js
+
svelte.config.js
modified .eslintrc.js
@@ -27,6 +27,6 @@ module.exports = {
    indent: ["error", 2, { "SwitchCase": 1 }]
  },
  settings: {
-
    "svelte3/typescript": true, 
+
    "svelte3/typescript": true,
  },
};
modified src/App.svelte
@@ -15,7 +15,7 @@

  function handleKeydown(event: KeyboardEvent) {
    if (event.key === 'Enter') {
-
      let elems = document.querySelectorAll('button.primary') as NodeListOf<HTMLElement>;
+
      let elems = document.querySelectorAll<HTMLElement>('button.primary');
      if (elems.length == 1) { // We only allow this when there's one primary button.
        elems[0].click();
      }
modified src/Error.svelte
@@ -7,8 +7,8 @@

  export let error: Err | null = null;
  export let title = "Error";
-
  export let subtitle: string = "";
-
  export let message: string = "";
+
  export let subtitle = "";
+
  export let message = "";
  export let floating = false;
  export let subtle = false;

modified src/Link.svelte
@@ -4,7 +4,7 @@
  export let to: string;
  export let primary = false;

-
  function getProps(_props: any) {
+
  function getProps(/* props: any */) {
    if (primary) {
      return { "class": "primary" };
    }
modified src/Options.svelte
@@ -3,7 +3,7 @@

  export let options: { label: string, value: string }[];
  export let name: string;
-
  export let selected: string = "";
+
  export let selected = "";
  export let disabled = false;

  const dispatch = createEventDispatcher();
modified src/base/home/Index.svelte
@@ -1,7 +1,7 @@
<script lang="typescript">
  import { navigate } from 'svelte-routing';

-
  let input: string = "";
+
  let input = "";
  const search = () => {
    navigate(`/resolver/query?${
      new URLSearchParams({ q: input })
modified src/base/projects/View.svelte
@@ -8,8 +8,8 @@
  import Browser from './Browser.svelte';

  export let urn: string;
-
  export let org: string = "";
-
  export let commit: string = "";
+
  export let org = "";
+
  export let commit = "";
  export let config: Config;
  export let path: string;

modified src/base/registrations/View.svelte
@@ -65,7 +65,7 @@
      }).catch(err => {
        state = { status: Status.Failed, error: err };
      });
-
    });
+
  });

  const onSave = async (event: { detail: Field[] }) => {
    assert(state.status === Status.Found, "registration must be found");
modified src/ens/SetName.svelte
@@ -21,7 +21,7 @@
    Failed,
  }

-
  let name: string = "";
+
  let name = "";
  let state = State.Idle;
  let mismatchError = false; // Set if the name entered does not resolve to the address.

modified src/project.ts
@@ -103,8 +103,8 @@ export async function getReadme(
export function path(
  opts: { urn: string, org?: string, commit?: string, path?: string }
): string {
-
  let { urn, org, commit, path } = opts;
-
  let result = [];
+
  const { urn, org, commit, path } = opts;
+
  const result = [];

  if (org) {
    result.push("orgs", org);
modified src/utils.ts
@@ -3,7 +3,6 @@ import type { BigNumber } from "ethers";
import multibase from 'multibase';
import multihashes from 'multihashes';
import type { Config } from '@app/config';
-
import { assert } from '@app/error';

export enum AddressType {
  Contract,