fix ui: small fixes

This commit is contained in:
nick-delirium 2024-07-05 10:56:18 +02:00
parent c3993e284d
commit a9d00c943f
No known key found for this signature in database
GPG key ID: 93ABD695DF5FDBA0
6 changed files with 2 additions and 13 deletions

View file

@ -16,9 +16,7 @@ interface Props {
function SpeedIndexByLocation(props: Props) {
const { data } = props;
console.log('data', data);
const wrapper: any = React.useRef(null);
let map: any = null;
const [tooltipStyle, setTooltipStyle] = React.useState({ display: 'none' });
const [pointedLocation, setPointedLocation] = React.useState<any>(null);
@ -27,7 +25,6 @@ function SpeedIndexByLocation(props: Props) {
const max = data.chart?.reduce((acc: any, item: any) => Math.max(acc, item.value), 0);
const min = data.chart?.reduce((acc: any, item: any) => Math.min(acc, item.value), 0);
data.chart?.forEach((item: any) => {
console.log('item', item);
if (!item || !item.userCountry) {
return;
}

View file

@ -113,7 +113,6 @@ function FilterSeries(props: Props) {
}
const onChangeEventsOrder = (_: any, {name, value}: any) => {
console.log(name, value)
series.filter.updateKey(name, value);
observeChanges();
};

View file

@ -80,8 +80,6 @@ const MetricListItem: React.FC<Props> = ({
const onRename = async () => {
try {
console.log('Renaming metric:', metric);
console.log('New name:', newName);
metric.name = newName;
// Add a toJson method if it doesn't exist
@ -93,14 +91,12 @@ const MetricListItem: React.FC<Props> = ({
category: this.category,
name: this.name,
metricType: this.metricType,
// Add other relevant properties here
};
};
}
await metricStore.save(metric.toJson());
console.log('Metric saved:', metric);
metricStore.fetchList();
setIsEdit(false);
} catch (e) {

View file

@ -41,7 +41,6 @@ const MetricTabs = ({metric, writeOption}: any) => {
if (![TABLE].includes(metric.metricType)) return null;
const onChange = (value: string) => {
console.log('value', value);
writeOption({
value: {
value
@ -232,8 +231,6 @@ const CardBuilder = observer((props: CardBuilderProps) => {
const isPredefined = [ERRORS, PERFORMANCE, RESOURCE_MONITORING, WEB_VITALS].includes(metric.metricType);
const testingKey = localStorage.getItem('__mauricio_testing_access') === 'true';
console.log('metric', metric);
useEffect(() => {
if (metric && !initialInstance) setInitialInstance(metric.toJson());

View file

@ -216,7 +216,7 @@ function Row({ test, siteId }: { test: UxTListEntry; siteId: string }) {
</div>
</div>
<div style={{ maxWidth: 550 }}>
<Link className="link" to={test.status === 'preview' ? editLink : link}>
<Link className="link !p-0" to={test.status === 'preview' ? editLink : link}>
{test.title}
</Link>
<div className={'text-disabled-text whitespace-nowrap text-ellipsis overflow-hidden'}>

View file

@ -145,7 +145,7 @@ function spawnDebugVideo(stream: MediaStream, node: VElement) {
video
.play()
.then(() => {
console.log('started streaming canvas');
console.debug('started streaming canvas');
})
.catch((e) => {
console.error(e);