text stringlengths 9 39.2M | dir stringlengths 25 226 | lang stringclasses 163
values | created_date timestamp[s] | updated_date timestamp[s] | repo_name stringclasses 751
values | repo_full_name stringclasses 752
values | star int64 1.01k 183k | len_tokens int64 1 18.5M |
|---|---|---|---|---|---|---|---|---|
```xml
import React from 'react';
import { connect } from 'react-redux';
import { reduxForm, formValueSelector } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import Controls from './Controls';
import { FORM_NAME } from '../../helpers/constants';
interface... | /content/code_sandbox/client/src/install/Setup/Submit.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 325 |
```xml
import React from 'react';
import { Trans, withTranslation } from 'react-i18next';
import { INSTALL_TOTAL_STEPS } from '../../helpers/constants';
const getProgressPercent = (step: any) => (step / INSTALL_TOTAL_STEPS) * 100;
type Props = {
step: number;
};
const Progress = (props: Props) => (
<div cla... | /content/code_sandbox/client/src/install/Setup/Progress.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 154 |
```xml
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { Field, reduxForm, formValueSelector } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import i18n, { TFunction } from 'i18next';
import Controls from './Controls'... | /content/code_sandbox/client/src/install/Setup/Settings.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 2,432 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { addErrorToast } from './toasts';
import { HTML_PAGES } from '../helpers/constants';
export const processLoginRequest = createAction('PROCESS_LOGIN_REQUEST');
export const processLoginFailure = createAction('PROCESS_LOGIN... | /content/code_sandbox/client/src/actions/login.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 172 |
```xml
import { createAction } from 'redux-actions';
import { showLoading, hideLoading } from 'react-redux-loading-bar';
import i18next from 'i18next';
import { normalizeFilteringStatus, normalizeRulesTextarea } from '../helpers/helpers';
import apiClient from '../api/Api';
import { addErrorToast, addSuccessToast } fr... | /content/code_sandbox/client/src/actions/filtering.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,524 |
```xml
import { createAction } from 'redux-actions';
import i18next from 'i18next';
import apiClient from '../api/Api';
import { addErrorToast, addSuccessToast } from './toasts';
import { splitByNewLine } from '../helpers/helpers';
export const getAccessListRequest = createAction('GET_ACCESS_LIST_REQUEST');
export c... | /content/code_sandbox/client/src/actions/access.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 704 |
```xml
import { sortIp, countClientsStatistics, findAddressType, subnetMaskToBitMask } from '../helpers/helpers';
import { ADDRESS_TYPES } from '../helpers/constants';
describe('sortIp', () => {
describe('ipv4', () => {
test('one octet differ', () => {
const arr = ['127.0.2.0', '127.0.3.0', '12... | /content/code_sandbox/client/src/__tests__/helpers.test.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 4,790 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { normalizeLogs } from '../helpers/helpers';
import { DEFAULT_LOGS_FILTER, FORM_NAME, QUERY_LOGS_PAGE_LIMIT } from '../helpers/constants';
import { addErrorToast, addSuccessToast } from './toasts';
const getLogsWithParams... | /content/code_sandbox/client/src/actions/queryLogs.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,483 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { normalizeTopStats, secondsToMilliseconds, getParamsForClientsSearch, addClientInfo } from '../helpers/helpers';
import { addErrorToast, addSuccessToast } from './toasts';
export const getStatsConfigRequest = createAction... | /content/code_sandbox/client/src/actions/stats.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 669 |
```xml
import { createAction } from 'redux-actions';
import i18next from 'i18next';
import apiClient from '../api/Api';
import { getClients } from './index';
import { addErrorToast, addSuccessToast } from './toasts';
export const toggleClientModal = createAction('TOGGLE_CLIENT_MODAL');
export const addClientRequest ... | /content/code_sandbox/client/src/actions/clients.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 478 |
```xml
import { createAction } from 'redux-actions';
import i18next from 'i18next';
import apiClient from '../api/Api';
import { splitByNewLine } from '../helpers/helpers';
import { addErrorToast, addSuccessToast } from './toasts';
export const getDnsConfigRequest = createAction('GET_DNS_CONFIG_REQUEST');
export con... | /content/code_sandbox/client/src/actions/dnsConfig.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 702 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { addErrorToast, addSuccessToast } from './toasts';
export const getBlockedServicesRequest = createAction('GET_BLOCKED_SERVICES_REQUEST');
export const getBlockedServicesFailure = createAction('GET_BLOCKED_SERVICES_FAILURE'... | /content/code_sandbox/client/src/actions/services.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 411 |
```xml
import { createAction } from 'redux-actions';
export const addErrorToast = createAction('ADD_ERROR_TOAST');
export const addSuccessToast = createAction('ADD_SUCCESS_TOAST');
export const addNoticeToast = createAction('ADD_NOTICE_TOAST');
``` | /content/code_sandbox/client/src/actions/toasts.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 49 |
```xml
import { createAction } from 'redux-actions';
import i18next from 'i18next';
import axios from 'axios';
import endsWith from 'lodash/endsWith';
import escapeRegExp from 'lodash/escapeRegExp';
import React from 'react';
import { compose } from 'redux';
import {
splitByNewLine,
sortClients,
filterOutC... | /content/code_sandbox/client/src/actions/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 5,932 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { addErrorToast, addSuccessToast } from './toasts';
export const nextStep = createAction('NEXT_STEP');
export const prevStep = createAction('PREV_STEP');
export const getDefaultAddressesRequest = createAction('GET_DEFAULT_... | /content/code_sandbox/client/src/actions/install.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 419 |
```xml
import { createAction } from 'redux-actions';
import apiClient from '../api/Api';
import { redirectToCurrentProtocol } from '../helpers/helpers';
import { addErrorToast, addSuccessToast } from './toasts';
export const getTlsStatusRequest = createAction('GET_TLS_STATUS_REQUEST');
export const getTlsStatusFailur... | /content/code_sandbox/client/src/actions/encryption.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 777 |
```xml
import { createAction } from 'redux-actions';
import i18next from 'i18next';
import apiClient from '../api/Api';
import { addErrorToast, addSuccessToast } from './toasts';
export const toggleRewritesModal = createAction('TOGGLE_REWRITES_MODAL');
export const getRewritesListRequest = createAction('GET_REWRITES_... | /content/code_sandbox/client/src/actions/rewrites.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 661 |
```xml
import { connect } from 'react-redux';
import { toggleProtection, getClients } from '../actions';
import { getStats, getStatsConfig, setStatsConfig } from '../actions/stats';
import { getAccessList } from '../actions/access';
import Dashboard from '../components/Dashboard';
import { RootState } from '../initia... | /content/code_sandbox/client/src/containers/Dashboard.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 215 |
```xml
import { connect } from 'react-redux';
import { initSettings, toggleSetting } from '../actions';
import { getBlockedServices, updateBlockedServices } from '../actions/services';
import { getStatsConfig, setStatsConfig, resetStats } from '../actions/stats';
import { clearLogs, getLogsConfig, setLogsConfig } from... | /content/code_sandbox/client/src/containers/Settings.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 225 |
```xml
import { connect } from 'react-redux';
import {
setRules,
getFilteringStatus,
addFilter,
removeFilter,
toggleFilterStatus,
toggleFilteringModal,
refreshFilters,
handleRulesChange,
editFilter,
} from '../actions/filtering';
import DnsBlocklist from '../components/Filters/DnsBl... | /content/code_sandbox/client/src/containers/DnsBlocklist.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 165 |
```xml
import { connect } from 'react-redux';
import { getClients } from '../actions';
import { getStats } from '../actions/stats';
import { addClient, updateClient, deleteClient, toggleClientModal } from '../actions/clients';
import Clients from '../components/Settings/Clients';
const mapStateToProps = (state: any)... | /content/code_sandbox/client/src/containers/Clients.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 244 |
```xml
import { connect } from 'react-redux';
import { getRewritesList, addRewrite, deleteRewrite, updateRewrite, toggleRewritesModal } from '../actions/rewrites';
import Rewrites from '../components/Filters/Rewrites';
import { RootState } from '../initialState';
const mapStateToProps = (state: RootState) => {
co... | /content/code_sandbox/client/src/containers/DnsRewrites.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 214 |
```xml
import { connect } from 'react-redux';
import { getAccessList, setAccessList } from '../actions/access';
import { getRewritesList, addRewrite, deleteRewrite, toggleRewritesModal } from '../actions/rewrites';
import { getDnsConfig, setDnsConfig } from '../actions/dnsConfig';
import Dns from '../components/Settin... | /content/code_sandbox/client/src/containers/Dns.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 198 |
```xml
import { connect } from 'react-redux';
import { getTlsStatus, setTlsConfig, validateTlsConfig } from '../actions/encryption';
import Encryption from '../components/Settings/Encryption';
const mapStateToProps = (state: any) => {
const { encryption } = state;
const props = {
encryption,
};
... | /content/code_sandbox/client/src/containers/Encryption.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 108 |
```xml
import { connect } from 'react-redux';
import * as actionCreators from '../actions';
import SetupGuide from '../components/SetupGuide';
const mapStateToProps = (state: any) => {
const { dashboard } = state;
const props = { dashboard };
return props;
};
export default connect(mapStateToProps, acti... | /content/code_sandbox/client/src/containers/SetupGuide.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 70 |
```xml
import { connect } from 'react-redux';
import {
setRules,
getFilteringStatus,
addFilter,
removeFilter,
toggleFilterStatus,
toggleFilteringModal,
refreshFilters,
handleRulesChange,
editFilter,
} from '../actions/filtering';
import DnsAllowlist from '../components/Filters/DnsAl... | /content/code_sandbox/client/src/containers/DnsAllowlist.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 165 |
```xml
import { connect } from 'react-redux';
import {
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
toggleLeaseModal,
addStaticLease,
removeStaticLease,
resetDhcp,
} from '../actions';
import Dhcp from '../components/Settings/Dhcp';
const mapStateToP... | /content/code_sandbox/client/src/containers/Dhcp.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 180 |
```xml
import { connect } from 'react-redux';
import { setRules, getFilteringStatus, handleRulesChange, checkHost } from '../actions/filtering';
import CustomRules from '../components/Filters/CustomRules';
import { RootState } from '../initialState';
const mapStateToProps = (state: RootState) => {
const { filteri... | /content/code_sandbox/client/src/containers/CustomRules.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 178 |
```xml
import React, { Component } from 'react';
import ReactModal from 'react-modal';
import { withTranslation } from 'react-i18next';
import { MODAL_TYPE } from '../../helpers/constants';
import Form from './Form';
import '../ui/Modal.css';
import { getMap } from '../../helpers/helpers';
ReactModal.setAppElement... | /content/code_sandbox/client/src/components/Filters/Modal.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 937 |
```xml
import React, { Component } from 'react';
// @ts-expect-error FIXME: update react-table
import ReactTable from 'react-table';
import { withTranslation, Trans } from 'react-i18next';
import CellWrap from '../ui/CellWrap';
import { MODAL_TYPE } from '../../helpers/constants';
import { formatDetailedDateTime } f... | /content/code_sandbox/client/src/components/Filters/Table.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,093 |
```xml
import axios from 'axios';
import { BASE_URL } from '../../constants';
import { getPathWithQueryString } from '../helpers/helpers';
import { QUERY_LOGS_PAGE_LIMIT, HTML_PAGES, R_PATH_LAST_PART, THEMES } from '../helpers/constants';
import i18n from '../i18n';
import { LANGUAGES } from '../helpers/twosky';
cla... | /content/code_sandbox/client/src/api/Api.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 4,537 |
```xml
import React, { Component } from 'react';
import { Trans, withTranslation } from 'react-i18next';
import Card from '../ui/Card';
import PageTitle from '../ui/PageTitle';
import Examples from './Examples';
import Check from './Check';
import { getTextareaCommentsHighlight, syncScroll } from '../../helpers/hi... | /content/code_sandbox/client/src/components/Filters/CustomRules.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 576 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
import PageTitle from '../ui/PageTitle';
import Card from '../ui/Card';
import Modal from './Modal';
import Actions from './Actions';
import Table from './Table';
import { MODAL_TYPE } from '../../helpers/constants';
im... | /content/code_sandbox/client/src/components/Filters/DnsBlocklist.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 976 |
```xml
import React from 'react';
import { withTranslation, Trans } from 'react-i18next';
interface ActionsProps {
handleAdd: (...args: unknown[]) => unknown;
handleRefresh: (...args: unknown[]) => unknown;
processingRefreshFilters: boolean;
whitelist?: boolean;
}
const Actions = ({ handleAdd, handleR... | /content/code_sandbox/client/src/components/Filters/Actions.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 207 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
import PageTitle from '../ui/PageTitle';
import Card from '../ui/Card';
import Modal from './Modal';
import Actions from './Actions';
import Table from './Table';
import { MODAL_TYPE } from '../../helpers/constants';
im... | /content/code_sandbox/client/src/components/Filters/DnsAllowlist.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 929 |
```xml
import React, { Fragment } from 'react';
import { withTranslation, Trans } from 'react-i18next';
const Examples = () => (
<Fragment>
<div className="list leading-loose">
<Trans>examples_title</Trans>:
<ol className="leading-loose">
<li>
<co... | /content/code_sandbox/client/src/components/Filters/Examples.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 351 |
```xml
import React from 'react';
import { Trans, withTranslation } from 'react-i18next';
import ReactModal from 'react-modal';
import { MODAL_TYPE } from '../../../helpers/constants';
import Form from './Form';
interface ModalProps {
isModalOpen: boolean;
handleSubmit: (values: any) => void;
toggleRewr... | /content/code_sandbox/client/src/components/Filters/Rewrites/Modal.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 372 |
```xml
import React, { Component } from 'react';
// @ts-expect-error FIXME: update react-table
import ReactTable from 'react-table';
import { withTranslation } from 'react-i18next';
import { sortIp } from '../../../helpers/helpers';
import { MODAL_TYPE, TABLES_MIN_ROWS } from '../../../helpers/constants';
import { Lo... | /content/code_sandbox/client/src/components/Filters/Rewrites/Table.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 755 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import classNames from 'classnames';
import { validatePath, validateRequiredValue } from '../../helpers/validators';
import { CheckboxField, renderInputFiel... | /content/code_sandbox/client/src/components/Filters/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,359 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { renderInputField } from '../../../helpers/form';
import { validateAnswer, validateDomain, validateRequiredValue } from '../../../helpers/val... | /content/code_sandbox/client/src/components/Filters/Rewrites/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 701 |
```xml
import React, { Component, Fragment } from 'react';
import { Trans, withTranslation } from 'react-i18next';
import Table from './Table';
import Modal from './Modal';
import Card from '../../ui/Card';
import PageTitle from '../../ui/PageTitle';
import { MODAL_TYPE } from '../../../helpers/constants';
import {... | /content/code_sandbox/client/src/components/Filters/Rewrites/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 648 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import classNames from 'classnames';
import i18next from 'i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import {
checkFiltered,
checkRewrite,
checkRewriteHosts,
checkWhiteList,
checkS... | /content/code_sandbox/client/src/components/Filters/Check/Info.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 973 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import { Field, reduxForm } from 'redux-form';
import { useSelector } from 'react-redux';
import Card from '../../ui/Card';
import { renderInputField } from '../../../helpers/form';
import Info from './Info';
import { FORM_NAME } from... | /content/code_sandbox/client/src/components/Filters/Check/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 391 |
```xml
import React, { useEffect } from 'react';
import { useTranslation } from 'react-i18next';
import { useDispatch, useSelector } from 'react-redux';
import Form from './Form';
import Card from '../../ui/Card';
import { getBlockedServices, getAllBlockedServices, updateBlockedServices } from '../../../actions/serv... | /content/code_sandbox/client/src/components/Filters/Services/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 520 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { toggleAllServices } from '../../../helpers/helpers';
import { renderServiceField } from '../../../helpers/form';
import { FORM_NAME } from ... | /content/code_sandbox/client/src/components/Filters/Services/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 520 |
```xml
import React from 'react';
import ct from 'countries-and-timezones';
import { useTranslation } from 'react-i18next';
import { LOCAL_TIMEZONE_VALUE } from '../../../../helpers/constants';
interface TimezoneProps {
timezone: string;
setTimezone: (...args: unknown[]) => unknown;
}
export const Timezone =... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/Timezone.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 268 |
```xml
import React from 'react';
import { getTimeFromMs } from './helpers';
interface TimePeriodProps {
startTimeMs: number;
endTimeMs: number;
}
export const TimePeriod = ({ startTimeMs, endTimeMs }: TimePeriodProps) => {
const startTime = getTimeFromMs(startTimeMs);
const endTime = getTimeFromMs(e... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/TimePeriod.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 131 |
```xml
export const getFullDayName = (t: any, abbreviation: any) => {
const dayMap = {
sun: t('sunday'),
mon: t('monday'),
tue: t('tuesday'),
wed: t('wednesday'),
thu: t('thursday'),
fri: t('friday'),
sat: t('saturday'),
};
return dayMap[abbreviation]... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/helpers.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 331 |
```xml
import React, { useState } from 'react';
import { getTimeFromMs, convertTimeToMs } from './helpers';
interface TimeSelectProps {
value: number;
onChange: (time: number) => void;
}
export const TimeSelect = ({ value, onChange }: TimeSelectProps) => {
const { hours: initialHours, minutes: initialMin... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/TimeSelect.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 370 |
```xml
import React, { useState, useEffect } from 'react';
import { useTranslation } from 'react-i18next';
import ReactModal from 'react-modal';
import { Timezone } from './Timezone';
import { TimeSelect } from './TimeSelect';
import { TimePeriod } from './TimePeriod';
import { getFullDayName, getShortDayName } fro... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/Modal.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,211 |
```css
.schedule__row {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 8px;
}
.schedule__row:last-child {
margin-bottom: 0;
}
.schedule__rows {
margin-bottom: 24px;
}
.schedule__day {
display: none;
min-width: 110px;
}
.schedule__day--mobile {
... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/styles.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 581 |
```xml
import { useEffect } from 'react';
import { connect } from 'react-redux';
import { ONE_SECOND_IN_MS } from '../../helpers/constants';
import { setProtectionTimerTime, toggleProtectionSuccess } from '../../actions';
let interval: any = null;
interface ProtectionTimerProps {
protectionDisabledDuration?: nu... | /content/code_sandbox/client/src/components/ProtectionTimer/index.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 289 |
```css
.toasts {
position: fixed;
right: 24px;
bottom: 24px;
z-index: 105;
width: 345px;
}
@media (max-width: 425px) {
.toasts {
right: 0;
width: 100%;
}
}
.toast {
display: flex;
align-items: flex-start;
margin-bottom: 12px;
padding: 16px;
font-weight: ... | /content/code_sandbox/client/src/components/Toasts/Toast.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 368 |
```xml
import React, { useState } from 'react';
import { useTranslation } from 'react-i18next';
import cn from 'classnames';
import { Modal } from './Modal';
import { getFullDayName, getShortDayName } from './helpers';
import { LOCAL_TIMEZONE_VALUE } from '../../../../helpers/constants';
import { TimePeriod } from '.... | /content/code_sandbox/client/src/components/Filters/Services/ScheduleForm/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 799 |
```xml
import React from 'react';
import { useSelector, shallowEqual } from 'react-redux';
import { CSSTransition, TransitionGroup } from 'react-transition-group';
import { TOAST_TRANSITION_TIMEOUT } from '../../helpers/constants';
import Toast from './Toast';
import './Toast.css';
import { RootState } from '../../in... | /content/code_sandbox/client/src/components/Toasts/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 182 |
```xml
import React, { useEffect, useState } from 'react';
import { Trans } from 'react-i18next';
import { useDispatch } from 'react-redux';
import { TOAST_TIMEOUTS } from '../../helpers/constants';
import { removeToast } from '../../actions';
interface ToastProps {
id: string;
message: string;
type: stri... | /content/code_sandbox/client/src/components/Toasts/Toast.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 369 |
```css
:root {
--black: #131313;
--bgcolor: #f5f7fb;
--mcolor: #495057;
--scolor: rgba(74, 74, 74, 0.7);
--border-color: rgba(0, 40, 100, 0.12);
--header-bgcolor: #fff;
--card-bgcolor: #fff;
--card-border-color: rgba(0, 40, 100, 0.12);
--ctrl-bgcolor: #fff;
--ctrl-select-bgcolor:... | /content/code_sandbox/client/src/components/App/index.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,315 |
```css
.form__button {
margin-left: 1.5rem;
}
@media (max-width: 500px) {
.form__button {
margin-left: 0;
margin-top: 1rem;
display: block;
}
}
``` | /content/code_sandbox/client/src/components/Settings/FormButton.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 55 |
```css
.form__group {
position: relative;
margin-bottom: 15px;
}
.form__group:last-child {
margin-bottom: 0;
}
.form__group--settings:last-child {
margin-bottom: 20px;
}
.form__group--inner {
max-width: 300px;
margin-top: -10px;
margin-left: 40px;
font-size: 14px;
}
.form__group--inp... | /content/code_sandbox/client/src/components/Settings/Settings.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 714 |
```xml
import React, { useEffect } from 'react';
import { HashRouter, Route } from 'react-router-dom';
import LoadingBar from 'react-redux-loading-bar';
import { hot } from 'react-hot-loader/root';
import 'react-table/react-table.css';
import '../ui/Tabler.css';
import '../ui/ReactTable.css';
import './index.css';
i... | /content/code_sandbox/client/src/components/App/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,355 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
import Card from '../../ui/Card';
import Form from './Form';
import { HOUR } from '../../../helpers/constants';
interface StatsConfigProps {
interval: number;
customInterval?: number;
ignored: unknown[];
... | /content/code_sandbox/client/src/components/Settings/StatsConfig/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 452 |
```xml
import React, { Component, Fragment } from 'react';
import { withTranslation } from 'react-i18next';
import StatsConfig from './StatsConfig';
import LogsConfig from './LogsConfig';
import FiltersConfig from './FiltersConfig';
import Checkbox from '../ui/Checkbox';
import Loading from '../ui/Loading';
impor... | /content/code_sandbox/client/src/components/Settings/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,278 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
import Card from '../../ui/Card';
import Form from './Form';
import { HOUR } from '../../../helpers/constants';
interface LogsConfigProps {
interval: number;
customInterval?: number;
enabled: boolean;
an... | /content/code_sandbox/client/src/components/Settings/LogsConfig/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 497 |
```xml
import React, { useEffect } from 'react';
import { change, Field, formValueSelector, reduxForm } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { connect } from 'react-redux';
import {
renderRadioField,
toNumber,
CheckboxField,
r... | /content/code_sandbox/client/src/components/Settings/StatsConfig/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,171 |
```xml
import React from 'react';
import { Trans, withTranslation } from 'react-i18next';
import ReactModal from 'react-modal';
import { MODAL_TYPE } from '../../../helpers/constants';
import Form from './Form';
const getInitialData = ({ initial, modalType, clientId, clientName }: any) => {
if (initial && initi... | /content/code_sandbox/client/src/components/Settings/Clients/Modal.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 545 |
```css
.service {
display: flex;
flex-direction: row-reverse;
align-items: center;
margin-bottom: 15px;
padding: 10px 15px;
border: 1px solid var(--card-border-color);
border-radius: 4px;
cursor: pointer;
}
.service__text {
text-overflow: ellipsis;
white-space: nowrap;
overf... | /content/code_sandbox/client/src/components/Settings/Clients/Service.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 564 |
```xml
import React, { useEffect } from 'react';
import { change, Field, formValueSelector, reduxForm } from 'redux-form';
import { connect } from 'react-redux';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import {
CheckboxField,
toFloatNumber,
renderTextareaFiel... | /content/code_sandbox/client/src/components/Settings/LogsConfig/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,239 |
```xml
import React, { Fragment } from 'react';
import { normalizeWhois } from '../../../helpers/helpers';
import { WHOIS_ICONS } from '../../../helpers/constants';
const getFormattedWhois = (value: any, t: any) => {
const whoisInfo = normalizeWhois(value);
const whoisKeys = Object.keys(whoisInfo);
if (w... | /content/code_sandbox/client/src/components/Settings/Clients/whoisCell.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 274 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
// @ts-expect-error FIXME: update react-table
import ReactTable from 'react-table';
import Card from '../../ui/Card';
import CellWrap from '../../ui/CellWrap';
import whoisCell from './whoisCell';
import LogsSearchLin... | /content/code_sandbox/client/src/components/Settings/Clients/AutoClients.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 729 |
```xml
import React, { Component, Fragment } from 'react';
import { withTranslation } from 'react-i18next';
import { ClientsTable } from './ClientsTable';
import AutoClients from './AutoClients';
import PageTitle from '../../ui/PageTitle';
import Loading from '../../ui/Loading';
import { ClientsData, DashboardData,... | /content/code_sandbox/client/src/components/Settings/Clients/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 480 |
```xml
export { default as ClientsTable } from './ClientsTable';
``` | /content/code_sandbox/client/src/components/Settings/Clients/ClientsTable/index.ts | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 13 |
```xml
/* eslint-disable react/display-name */
/* eslint-disable react/prop-types */
import React, { useEffect } from 'react';
import { Trans, useTranslation } from 'react-i18next';
import { useDispatch, useSelector } from 'react-redux';
import { useHistory, useLocation } from 'react-router-dom';
// @ts-expect-error ... | /content/code_sandbox/client/src/components/Settings/Clients/ClientsTable/ClientsTable.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 2,522 |
```xml
import React, { useEffect } from 'react';
import { useTranslation } from 'react-i18next';
import { useDispatch, useSelector } from 'react-redux';
import Upstream from './Upstream';
import Access from './Access';
import Config from './Config';
import PageTitle from '../../ui/PageTitle';
import Loading from ... | /content/code_sandbox/client/src/components/Settings/Dns/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 271 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import Card from '../../../ui/Card';
import Form from './Form';
import { setDnsConfig } from '../../../../actions/dnsConfig';
import { replaceEmptyStringsWithZeroes,... | /content/code_sandbox/client/src/components/Settings/Dns/Cache/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 319 |
```xml
import React, { useState } from 'react';
import { connect, useSelector } from 'react-redux';
import { Field, FieldArray, reduxForm, formValueSelector, FormErrors } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import Select from 'react-select';
impor... | /content/code_sandbox/client/src/components/Settings/Clients/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 3,045 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Trans, useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import { renderInputField, toNumber, CheckboxField } from '../../../../helpers/form';
import { CACHE_CONFIG_FIEL... | /content/code_sandbox/client/src/components/Settings/Dns/Cache/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 886 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import Form from './Form';
import Card from '../../../ui/Card';
import { setDnsConfig } from '../../../../actions/dnsConfig';
import { RootState } from '../../../../i... | /content/code_sandbox/client/src/components/Settings/Dns/Upstream/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 426 |
```xml
import React from 'react';
import { Trans, withTranslation } from 'react-i18next';
import { COMMENT_LINE_DEFAULT_TOKEN } from '../../../../helpers/constants';
interface ExamplesProps {
t: (...args: unknown[]) => string;
}
const Examples = (props: ExamplesProps) => (
<div className="list leading-loose">... | /content/code_sandbox/client/src/components/Settings/Dns/Upstream/Examples.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,099 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import Card from '../../../ui/Card';
import Form from './Form';
import { setDnsConfig } from '../../../../actions/dnsConfig';
import { RootState } from '../../../../i... | /content/code_sandbox/client/src/components/Settings/Dns/Config/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 372 |
```xml
import React, { useRef } from 'react';
import { useDispatch, useSelector } from 'react-redux';
import { Field, reduxForm } from 'redux-form';
import { Trans, useTranslation } from 'react-i18next';
import classnames from 'classnames';
import Examples from './Examples';
import { renderRadioField, renderTextarea... | /content/code_sandbox/client/src/components/Settings/Dns/Upstream/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 2,244 |
```xml
import React from 'react';
import { useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import Form from './Form';
import Card from '../../../ui/Card';
import { setAccessList } from '../../../../actions/access';
import { RootState } from '../../../../ini... | /content/code_sandbox/client/src/components/Settings/Dns/Access/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 193 |
```xml
import React from 'react';
import { shallowEqual, useSelector } from 'react-redux';
import { Field, reduxForm } from 'redux-form';
import { Trans, useTranslation } from 'react-i18next';
import {
renderInputField,
renderRadioField,
renderTextareaField,
CheckboxField,
toNumber,
} from '../../.... | /content/code_sandbox/client/src/components/Settings/Dns/Config/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 2,093 |
```xml
import React from 'react';
import { withTranslation } from 'react-i18next';
import debounce from 'lodash/debounce';
import { DEBOUNCE_TIMEOUT } from '../../../helpers/constants';
import Form from './Form';
import { getObjDiff } from '../../../helpers/helpers';
interface FiltersConfigProps {
initialValues... | /content/code_sandbox/client/src/components/Settings/FiltersConfig/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 219 |
```xml
import React from 'react';
import { connect } from 'react-redux';
import { Field, reduxForm, formValueSelector } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { renderTextareaField } from '../../../../helpers/form';
import { trimMultilineStrin... | /content/code_sandbox/client/src/components/Settings/Dns/Access/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 774 |
```xml
import React, { Fragment } from 'react';
import { withTranslation, Trans } from 'react-i18next';
interface KeyStatusProps {
validKey: boolean;
keyType: string;
}
const KeyStatus = ({ validKey, keyType }: KeyStatusProps) => (
<Fragment>
<div className="form__label form__label--bold">
... | /content/code_sandbox/client/src/components/Settings/Encryption/KeyStatus.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 183 |
```xml
import React, { Fragment } from 'react';
import { withTranslation, Trans } from 'react-i18next';
import format from 'date-fns/format';
import { EMPTY_DATE } from '../../../helpers/constants';
interface CertificateStatusProps {
validChain: boolean;
validCert: boolean;
subject?: string;
issuer?: ... | /content/code_sandbox/client/src/components/Settings/Encryption/CertificateStatus.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 378 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { CheckboxField, toNumber } from '../../../helpers/form';
import { FILTERS_INTERVALS_HOURS, FILTERS_RELATIVE_LINK, FORM_NAME } from '../../../... | /content/code_sandbox/client/src/components/Settings/FiltersConfig/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 596 |
```xml
import React, { Component } from 'react';
import { withTranslation } from 'react-i18next';
import debounce from 'lodash/debounce';
import { DEBOUNCE_TIMEOUT, ENCRYPTION_SOURCE } from '../../../helpers/constants';
import Form from './Form';
import Card from '../../ui/Card';
import PageTitle from '../../ui/Pag... | /content/code_sandbox/client/src/components/Settings/Encryption/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 791 |
```xml
import React, { Component } from 'react';
import { connect } from 'react-redux';
// @ts-expect-error FIXME: update react-table
import ReactTable from 'react-table';
import { Trans, withTranslation } from 'react-i18next';
import { LEASES_TABLE_DEFAULT_PAGE_SIZE, MODAL_TYPE } from '../../../helpers/constants';
i... | /content/code_sandbox/client/src/components/Settings/Dhcp/Leases.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 667 |
```css
.dhcp-form__button {
margin: 0 1rem;
}
.page-title--dhcp {
display: flex;
align-items: center;
}
.col__dhcp {
flex: 0 0 50%;
max-width: 50%;
padding-right: 0;
}
.dhcp__interfaces {
padding-bottom: 1rem;
}
.dhcp__interfaces-info {
padding: 0.5rem 0.75rem 0;
line-break: anyw... | /content/code_sandbox/client/src/components/Settings/Dhcp/index.css | css | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 235 |
```xml
import React, { useCallback } from 'react';
import { shallowEqual, useSelector } from 'react-redux';
import { Field, reduxForm } from 'redux-form';
import { useTranslation } from 'react-i18next';
import { renderInputField, toNumber } from '../../../helpers/form';
import { FORM_NAME, UINT32_RANGE } from '../../... | /content/code_sandbox/client/src/components/Settings/Dhcp/FormDHCPv6.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 890 |
```xml
import React, { useCallback } from 'react';
import { shallowEqual, useSelector } from 'react-redux';
import { Field, reduxForm } from 'redux-form';
import { useTranslation } from 'react-i18next';
import { renderInputField, toNumber } from '../../../helpers/form';
import { FORM_NAME, UINT32_RANGE } from '../../... | /content/code_sandbox/client/src/components/Settings/Dhcp/FormDHCPv4.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,138 |
```xml
import React from 'react';
import { connect } from 'react-redux';
import { Field, reduxForm, formValueSelector } from 'redux-form';
import { Trans, withTranslation } from 'react-i18next';
import flow from 'lodash/flow';
import { renderInputField, CheckboxField, renderRadioField, toNumber } from '../../../helpe... | /content/code_sandbox/client/src/components/Settings/Encryption/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 3,298 |
```xml
import React from 'react';
import { shallowEqual, useSelector } from 'react-redux';
import { Field, reduxForm } from 'redux-form';
import { Trans, useTranslation } from 'react-i18next';
import { renderSelectField } from '../../../helpers/form';
import { validateRequiredValue } from '../../../helpers/validators... | /content/code_sandbox/client/src/components/Settings/Dhcp/Interfaces.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 757 |
```xml
import React, { useEffect, useState } from 'react';
import { Trans, useTranslation } from 'react-i18next';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import classNames from 'classnames';
import { destroy } from 'redux-form';
import { DHCP_DESCRIPTION_PLACEHOLDERS, DHCP_FORM_NAMES, ST... | /content/code_sandbox/client/src/components/Settings/Dhcp/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 2,155 |
```xml
import React from 'react';
import { Trans, withTranslation } from 'react-i18next';
import ReactModal from 'react-modal';
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
import Form from './Form';
import { toggleLeaseModal } from '../../../../actions';
import { MODAL_TYPE } from '../../..... | /content/code_sandbox/client/src/components/Settings/Dhcp/StaticLeases/Modal.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 462 |
```xml
import React from 'react';
// @ts-expect-error FIXME: update react-table
import ReactTable from 'react-table';
import { Trans, useTranslation } from 'react-i18next';
import { useDispatch } from 'react-redux';
import { LEASES_TABLE_DEFAULT_PAGE_SIZE, MODAL_TYPE } from '../../../../helpers/constants';
import { s... | /content/code_sandbox/client/src/components/Settings/Dhcp/StaticLeases/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 966 |
```xml
import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Trans, useTranslation } from 'react-i18next';
import { useDispatch, useSelector, shallowEqual } from 'react-redux';
import { renderInputField, normalizeMac } from '../../../../helpers/form';
import {
validateIpv4,
valida... | /content/code_sandbox/client/src/components/Settings/Dhcp/StaticLeases/Form.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 712 |
```xml
import React, { Component } from 'react';
import { NavLink } from 'react-router-dom';
import enhanceWithClickOutside from 'react-click-outside';
import classnames from 'classnames';
import { Trans, withTranslation } from 'react-i18next';
import { SETTINGS_URLS, FILTERS_URLS, MENU_URLS } from '../../helpers/con... | /content/code_sandbox/client/src/components/Header/Menu.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 1,035 |
```xml
import React, { useState } from 'react';
import { Link, useLocation } from 'react-router-dom';
import { shallowEqual, useSelector } from 'react-redux';
import { useTranslation } from 'react-i18next';
import classnames from 'classnames';
import Menu from './Menu';
import { Logo } from '../ui/svg/logo';
import ... | /content/code_sandbox/client/src/components/Header/index.tsx | xml | 2016-07-06T10:31:47 | 2024-08-16T18:17:06 | AdGuardHome | AdguardTeam/AdGuardHome | 24,082 | 495 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.