mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-29 05:31:51 +02:00
Option to disable telemetry
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import type { Cookie } from '@yaakapp/api';
|
||||
import { useCookieJars } from '../hooks/useCookieJars';
|
||||
import { useUpdateCookieJar } from '../hooks/useUpdateCookieJar';
|
||||
import type { Cookie } from '../lib/models/Cookie';
|
||||
import { cookieDomain } from '../lib/models';
|
||||
import { Banner } from './core/Banner';
|
||||
import { IconButton } from './core/IconButton';
|
||||
|
||||
@@ -77,6 +77,12 @@ export function SettingsGeneral() {
|
||||
{ label: 'New Window', value: 'new' },
|
||||
]}
|
||||
/>
|
||||
<Checkbox
|
||||
checked={settings.telemetry}
|
||||
title="Send Usage Statistics"
|
||||
onChange={(telemetry) => updateSettings.mutate({ telemetry })}
|
||||
/>
|
||||
|
||||
<Separator className="my-4" />
|
||||
|
||||
<Heading size={2}>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import type { CookieJar } from '../lib/models';
|
||||
import type { CookieJar } from '@yaakapp/api';
|
||||
import { invokeCmd } from '../lib/tauri';
|
||||
import { useActiveWorkspace } from './useActiveWorkspace';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useMutation } from '@tanstack/react-query';
|
||||
import type { CookieJar } from '@yaakapp/api';
|
||||
import { trackEvent } from '../lib/analytics';
|
||||
import type { CookieJar } from '../lib/models';
|
||||
import { invokeCmd } from '../lib/tauri';
|
||||
import { useActiveWorkspace } from './useActiveWorkspace';
|
||||
import { usePrompt } from './usePrompt';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useMutation } from '@tanstack/react-query';
|
||||
import type { CookieJar } from '@yaakapp/api';
|
||||
import { InlineCode } from '../components/core/InlineCode';
|
||||
import { trackEvent } from '../lib/analytics';
|
||||
import type { CookieJar } from '../lib/models';
|
||||
import { invokeCmd } from '../lib/tauri';
|
||||
import { useConfirm } from './useConfirm';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { Settings } from '@yaakapp/api';
|
||||
import { useAtomValue } from 'jotai';
|
||||
import { atom } from 'jotai/index';
|
||||
import type { Settings } from '../lib/models/Settings';
|
||||
import { getSettings } from '../lib/store';
|
||||
|
||||
const settings = await getSettings();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useMutation } from '@tanstack/react-query';
|
||||
import type { CookieJar } from '../lib/models';
|
||||
import type { CookieJar } from '@yaakapp/api';
|
||||
import { getCookieJar } from '../lib/store';
|
||||
import { invokeCmd } from '../lib/tauri';
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useMutation } from '@tanstack/react-query';
|
||||
import type { Settings } from '../lib/models';
|
||||
import type { Settings } from '@yaakapp/api';
|
||||
import { getSettings } from '../lib/store';
|
||||
import { invokeCmd } from '../lib/tauri';
|
||||
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
import type { GrpcConnection, HttpResponse, HttpResponseHeader, Model } from '@yaakapp/api';
|
||||
import type { Cookie } from './models/Cookie';
|
||||
import type { CookieJar } from './models/CookieJar';
|
||||
import type { Settings } from './models/Settings';
|
||||
|
||||
export type { CookieJar, Cookie, Settings };
|
||||
import type { Cookie, GrpcConnection, HttpResponse, HttpResponseHeader, Model } from '@yaakapp/api';
|
||||
|
||||
export const BODY_TYPE_NONE = null;
|
||||
export const BODY_TYPE_GRAPHQL = 'graphql';
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { CookieDomain } from "./CookieDomain";
|
||||
import type { CookieExpires } from "./CookieExpires";
|
||||
|
||||
export type Cookie = { raw_cookie: string, domain: CookieDomain, expires: CookieExpires, path: [string, boolean], };
|
||||
@@ -1,3 +0,0 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type CookieDomain = { "HostOnly": string } | { "Suffix": string } | "NotPresent" | "Empty";
|
||||
@@ -1,3 +0,0 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type CookieExpires = { "AtUtc": string } | "SessionEnd";
|
||||
@@ -1,4 +0,0 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { Cookie } from "./Cookie";
|
||||
|
||||
export type CookieJar = { id: string, model: "cookie_jar", createdAt: string, updatedAt: string, workspaceId: string, name: string, cookies: Array<Cookie>, };
|
||||
@@ -1,3 +0,0 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Settings = { id: string, model: "settings", createdAt: string, updatedAt: string, theme: string, appearance: string, themeDark: string, themeLight: string, updateChannel: string, interfaceFontSize: number, interfaceScale: number, editorFontSize: number, editorSoftWrap: boolean, openWorkspaceNewWindow: boolean | null, };
|
||||
@@ -1,6 +1,12 @@
|
||||
import type { Environment, Folder, GrpcRequest, HttpRequest, Workspace } from '@yaakapp/api';
|
||||
import type { CookieJar } from './models/CookieJar';
|
||||
import type { Settings } from './models/Settings';
|
||||
import type {
|
||||
CookieJar,
|
||||
Environment,
|
||||
Folder,
|
||||
GrpcRequest,
|
||||
HttpRequest,
|
||||
Settings,
|
||||
Workspace,
|
||||
} from '@yaakapp/api';
|
||||
import { invokeCmd } from './tauri';
|
||||
|
||||
export async function getSettings(): Promise<Settings> {
|
||||
|
||||
Reference in New Issue
Block a user