Id
int64
1.68k
75.6M
PostTypeId
int64
1
2
AcceptedAnswerId
int64
1.7k
75.6M
ParentId
int64
1.68k
75.6M
Score
int64
-60
3.16k
ViewCount
int64
8
2.68M
Body
stringlengths
1
41.1k
Title
stringlengths
14
150
ContentLicense
stringclasses
3 values
FavoriteCount
int64
0
1
CreationDate
stringlengths
23
23
LastActivityDate
stringlengths
23
23
LastEditDate
stringlengths
23
23
LastEditorUserId
int64
-1
21.3M
OwnerUserId
int64
1
21.3M
Tags
sequence
74,058,861
2
null
74,058,208
1
null
The `border-radius` on `<img>` is the reason why they are clipped at the corners. Apply `border-radius` to the element that contains the `<img>`, also if you want a perfect circle it should be `border-radius: 50%`. The other changes are just added for the sake of completeness. The changes to HTML are optional. `/* ✢ */` ``` .bar { display: flex; justify-content: space-evenly; /* ✢ */ align-items: center; margin-top: 20px; padding-bottom: 12px; border-bottom: 1px solid rgb(65, 65, 65); } .orb { display: inline-flex; /* ✢ */ justify-content: center; /* ✢ */ align-items: center; /* ✢ */ border-radius: 50%; /* ✢ */ background-color: rgba(13, 13, 13, 0.4); } .ico { display: inline-block; /* ✢ */ width: 20px; height: 20px; padding: 9px /* ✢ */ } ``` ``` <nav class="bar"> <a href="#" class="orb"> <img class="ico" src="https://i.ibb.co/bBNQZW2/stop-1470.png"> </a> <a href="#" class="orb"> <img class="ico" src="https://i.ibb.co/Hx860HY/arrow-all-376.png"> </a> <a href="#" class="orb"> <img class="ico" src="https://i.ibb.co/JjNnNsb/javascript-155.png"> </a> </nav> ```
null
CC BY-SA 4.0
null
2022-10-13T16:12:20.980
2022-10-13T16:12:20.980
null
null
2,813,224
null
74,058,986
2
null
45,132,731
0
null
Set the child components height without using % e.g make `minHeight: '10%'` -> `minHeight: 10`
null
CC BY-SA 4.0
null
2022-10-13T16:22:23.940
2022-10-13T16:22:39.193
2022-10-13T16:22:39.193
20,233,364
20,233,364
null
74,059,430
2
null
74,058,859
1
null
> LISTEN 0 4096 127.0.0.1:8123 0.0.0.0:* expected: ``` LISTEN 0 4096 *:8123 *:* ``` Your Clickhouse listens localhost only solution: ``` cat /etc/clickhouse-server/config.d/port.xml <?xml version="1.0"?> <yandex> <listen_host>::</listen_host> </yandex> ``` and restart CH.
null
CC BY-SA 4.0
null
2022-10-13T17:06:25.477
2022-10-13T17:06:25.477
null
null
11,644,308
null
74,059,929
2
null
51,850,202
0
null
I have used Treeview from: ``` xmlns:muxc="using:Windows.UI.Xaml.Controls" ``` Suppose I have a class: ``` class Category { public string Name {get; set;} public ObservableCollection<Category> Subcategories {get; set;} } ``` Then I bind the treeview with the itemsource: ``` ObservableCollection<Category> Categories {get; set;} ``` of viewmodel. And my xaml looks like this: ``` <muxc:TreeView SelectionMode="Multiple" Width="300" x:Name="CategoriesTree" ItemsSource="{x:Bind _vm.Categories, Mode=OneWay}"> <muxc:TreeView.ItemTemplate> <DataTemplate x:DataType="local1:ProductCategoriesInfo"> <TreeViewItem ItemsSource="{x:Bind SubCategories}" Content="{x:Bind Name}" /> </DataTemplate> </muxc:TreeView.ItemTemplate> </muxc:TreeView> ```
null
CC BY-SA 4.0
null
2022-10-13T17:56:05.373
2022-10-13T17:56:05.373
null
null
14,411,884
null
74,060,017
2
null
74,051,620
0
null
Here is how you have to do that in Imagemagick. Your image already has an alpha channel. So you have to create a new grayscale gradient image as a mask and combine that with the existing alpha channel. (The -sparse-color is going to write over your existing alpha channel.) ``` magick face.png \ \( -clone 0 -alpha extract \) \ \( -clone 0 -sparse-color barycentric "0,%[fx:h*0.90] white 0,%[h] black" \) \ \( -clone 1,2 -compose multiply -composite \) \ -delete 1,2 \ -alpha off -compose copy_opacity -composite face-gradient.png ``` [](https://i.stack.imgur.com/pIAhc.png)
null
CC BY-SA 4.0
null
2022-10-13T18:05:16.643
2022-10-13T21:54:05.883
2022-10-13T21:54:05.883
7,355,741
7,355,741
null
74,060,461
2
null
74,060,299
0
null
If all these documents in `products` collection have something in common, you can [use a collection group query](https://firebase.google.com/docs/firestore/query-data/queries#collection-group-query) to select documents across all of them. For example, if there's a field identifying the product in each `products` document, you can do: ``` FirebaseFirestore.instance .collectionGroup("products") .where("product", isEqualTo: "productYouWantToShow") .snapshots() ```
null
CC BY-SA 4.0
null
2022-10-13T18:49:40.717
2022-10-13T18:49:40.717
null
null
209,103
null
74,060,500
2
null
30,613,031
0
null
Here is the fix that worked for me, it seems that you need to tell it what index it should be at before trying to assign items to it ``` Private Sub Top_GotFocus() Dim i As Integer MainProgram.InitVars 'Initializes the Varibles needed.-- Sheets("Design").Top.Clear 'Clears the DropDown List.-- Erase MainProgram.Tops() 'Clears the Tops array.-- MainProgram.GetStdType "top", MainProgram.Tops(), "d", True 'Fills Array with all Tops found in "D# Standards" and sorts them alphabetically.-- If MainProgram.IsArrayEmpty(MainProgram.Tops) = False Then 'If the tops array is NOT empty add the array items to the dropdown list.-- Top.ListIndex = -1 '<------ (FIXED IT FOR ME) Sheets("Design").Top.List = MainProgram.Tops '(i), i 'Adds the tops(i) value to the Dropdown box.-- End If End Sub ```
null
CC BY-SA 4.0
null
2022-10-13T18:54:08.967
2022-10-13T18:54:08.967
null
null
20,234,323
null
74,060,660
2
null
74,059,638
0
null
hmmm normally you can use custom tab and it will handle the deeplinks heres what i have for you first you use `@Override public boolean shouldOverrideUrlLoading(WebView view, String url) {}` then you create intent `Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.google.com"));` then you query the Apps that can handle it `PackageManager packageManager = context.getPackageManager(); List<ResolveInfo> resolvedActivities = packageManager.queryIntentActivities(browserIntent , 0);` you can Use loadLabel() on the ResolveInfo to get a "user friendly label" i don't have the full solutation as it is new for me but if you only need the webview to be part of your app only use [ChromeTab](https://developer.chrome.com/docs/android/custom-tabs/integration-guide/) hope this can help
null
CC BY-SA 4.0
null
2022-10-13T19:08:16.777
2022-10-13T19:08:16.777
null
null
16,290,160
null
74,061,101
2
null
23,363,073
0
null
Following this article I found I had to add a reference and remove a package. I'm using vs 2022 but same goes for 2019. Found this page has the information to fix my issue. I found there are two ways to fix it. I have framework 4.8 And reference to Microsoft.VisualStudio.QualityTools.UnitTestFramework The classes [TestClass] and [TestMethod] where visible because of a package installed, but adding that those attribute calsses where defined in the package and the added UnitTestFramework reference. Remove the package and showed it was ok running and debugging tests. This is done another way by adding two packages. And you can add one package that will include the second. Package Id's are: Microsoft.UnitTestFramework.Extensions MSTest.TestFramework I believe the two package add is better than the one reference to assembly: C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\ReferenceAssemblies\v2.0\Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll
null
CC BY-SA 4.0
null
2022-10-13T19:52:38.087
2022-10-13T19:52:38.087
null
null
5,947,840
null
74,061,819
2
null
74,061,193
1
null
As of R 4.1, we can define clipping masks in grid graphics. Convert your magick image to a rasterGrob and draw it in a viewport that has a mask made from your triangle co-ordinates. The following is a full reprex: ``` library(magick) #> Linking to ImageMagick 6.9.12.3 #> Enabled features: cairo, freetype, fftw, ghostscript, heic, lcms, pango, raw, rsvg, webp #> Disabled features: fontconfig, x11 library(grid) url <- paste0("https://upload.wikimedia.org/wikipedia/commons/", "b/b3/USA-NYC-Empire_State1.JPG") ESB <- image_read(url) ESB2 <- image_resize(ESB, "500x500") ESB_grob <- rasterGrob(ESB2) mask <- as.mask(polygonGrob(x = c(0.285, 0.5, 0.715, 0.285), y = c(0.1, 0.9, 0.1, 0.1))) grid.newpage() pushViewport(viewport(mask = mask)) grid.draw(ESB_grob) ``` [](https://i.stack.imgur.com/Gwk44.png) [reprex v2.0.2](https://reprex.tidyverse.org)
null
CC BY-SA 4.0
null
2022-10-13T21:08:51.143
2022-10-13T21:08:51.143
null
null
12,500,315
null
74,062,347
2
null
74,057,668
0
null
You didn't show what result you expect but you can always use ``` df[k + ' col'] = df.Desc.map(...) + "," + df.Desc1.map(...) ``` But this will add `,` in empty cell and it will repeate duplicated values. ``` import pandas as pd df = pd.DataFrame({ 'Desc': ['cat is black', 'dog is white'], 'Desc1': ['cat is white', 'dog is white'], }) kw = ['cat','dog'] for k in kw: df[k + ' col'] = df.Desc.map(lambda s: s if k in s else '') + ',' + df.Desc1.map(lambda s: s if k in s else '') print(df.to_string()) ``` Result: ``` Desc Desc1 cat col dog col 0 cat is black cat is white cat is black,cat is white , 1 dog is white dog is white , dog is white,dog is white ``` --- But you can also use `.apply(function, args=[...], axis=1)` to send full row to function and run more complex code in function ``` import pandas as pd df = pd.DataFrame({ 'Desc': ['cat is black', 'dog is white'], 'Desc1': ['cat is white', 'dog is white'], }) def select(row, word): result = [] if word in row['Desc']: result.append(row['Desc']) if word in row['Desc1']: result.append(row['Desc1']) # skip duplicated if len(result) > 1 and result[0] == result[1]: result = result[:1] return ",".join(result) kw = ['cat','dog'] for word in kw: df[f'{word} col'] = df.apply(select, args=[word], axis=1) print(df.to_string()) ``` Result: ``` Desc Desc1 cat col dog col 0 cat is black cat is white cat is black,cat is white 1 dog is white dog is white dog is white ```
null
CC BY-SA 4.0
null
2022-10-13T22:13:11.063
2022-10-13T22:13:11.063
null
null
1,832,058
null
74,062,571
2
null
73,957,259
0
null
Azure AD app registration is backed by 2 directory objects: an application and a service principal. As its name implies, the latter is the principal for authentication/authorization. Thus, you will see 2 object ids. Regarding the access issue, all the principal (user or service) needs is an [RBAC role assigned](https://learn.microsoft.com/en-us/azure/storage/blobs/assign-azure-role-data-access?tabs=portal#assign-an-azure-role), thus adding or removing application permissions won't make a difference.
null
CC BY-SA 4.0
null
2022-10-13T22:47:05.390
2022-10-13T22:47:05.390
null
null
5,562,372
null
74,062,681
2
null
74,045,604
0
null
This could be wrong version for MacOS ARM architecture (M1 chip): Version: 2022-09 (4.25.0) Build id: 20220908-1902 Is this Mac book of M1 chip or Intel? I had the same issue with the same version on my Mac book with M1 chip. I installed the right eclipse version from "https://www.eclipse.org/downloads/" --> choose "AArch64" direct link: [https://www.eclipse.org/downloads/download.php?file=/oomph/epp/2022-09/R/eclipse-inst-jre-mac-aarch64.dmg](https://www.eclipse.org/downloads/download.php?file=/oomph/epp/2022-09/R/eclipse-inst-jre-mac-aarch64.dmg)
null
CC BY-SA 4.0
null
2022-10-13T23:04:41.200
2022-10-13T23:04:41.200
null
null
7,054,922
null
74,062,841
2
null
74,060,382
1
null
I responded to a similar [question](https://stackoverflow.com/questions/73783983/react-native-vertical-auto-slide-animation-infinite/73785593#73785593) and recommended [react-native-swiper](https://github.com/leecade/react-native-swiper) as it has the swiping functionality built in out of the box (this isnt enabled for web): ``` import React, { useState } from 'react'; import { Text, View, StyleSheet, FlatList } from 'react-native'; import Constants from 'expo-constants'; import Swiper from 'react-native-swiper'; import { colorGenerator, colorManipulators, } from '@phantom-factotum/colorutils'; const totalItems = 4; export default function App() { const DATA = colorGenerator(totalItems).map((color, index) => ({ color, textColor: colorManipulators.darkenColor(color, 0.45), title: 'Item' + (index + 1), })); return ( <View style={styles.container}> <Swiper style={styles.wrapper} showsButtons={true} horizontal={true}> {DATA.map((item, i) => { return ( <View style={[styles.item, { backgroundColor: item.color }]} key={item.title}> <Text style={[styles.text, { color: item.textColor }]}> {item.title} </Text> </View> ); })} </Swiper> </View> ); } const styles = StyleSheet.create({ container: { flex: 1, justifyContent: 'center', paddingTop: Constants.statusBarHeight, backgroundColor: '#ecf0f1', padding: 8, }, wrapper: { // flex: 1, }, item: { flex: 1, justifyContent: 'center', alignItems: 'center', }, text: { fontSize: 30, fontWeight: 'bold', }, }); ``` Here's the [demo](https://snack.expo.dev/BMUUJwsuF)
null
CC BY-SA 4.0
null
2022-10-13T23:29:27.597
2022-10-13T23:29:27.597
null
null
12,611,354
null
74,062,879
2
null
69,515,086
0
null
This error message indicates you have an old version of Beautiful Soup. The issue was already [fixed](https://bazaar.launchpad.net/%7Eleonardr/beautifulsoup/bs4/revision/452) back in Beautiful Soup 4.6.1, a release that came out in 2018. As of this writing, Beautiful Soup is up to version 4.11.1. Update your Beautiful Soup, and the problem should be resolved.
null
CC BY-SA 4.0
null
2022-10-13T23:37:57.673
2022-10-21T15:59:48.633
2022-10-21T15:59:48.633
63,550
2,357,112
null
74,063,185
2
null
74,049,554
0
null
I figured it out. I had to put group into both the geom_errorbar and geom_point: ``` ggplot(NULL, aes(x, y)) + geom_jitter(SWC, mapping = aes(x = Date.Order, y = Water_Vol, colour = Site), width = 5) + geom_errorbar(watervol.time, mapping = aes(Date.Order, y = water.vol.mean, ymin = LCI, ymax = UCI, group = Site), width = 10, position = position_dodge(10)) + geom_point(data = watervol.time, mapping = aes(Date.Order, y = water.vol.mean, fill = Site, group = Site), shape = 21, size = 3.5, position = position_dodge(10)) + scale_fill_manual(values = c('blue', 'green', 'yellow', 'red')) + scale_colour_manual(values = c('blue', 'green', 'yellow', 'red')) ```
null
CC BY-SA 4.0
null
2022-10-14T00:41:09.027
2022-10-14T00:41:09.027
null
null
19,662,958
null
74,063,431
2
null
74,061,054
0
null
You can use this to create a spreadsheets with sheets that represents the months of the current year. It will will be easy to locate week ends because they are the last two columns on the right. The first function is just a helper function. The other one is the one you should call. ``` function monthlyCalendar11(m, wsd, ret, sh, ss) { sh.clear(); const td = new Date(); const [cy, cm, cd] = [td.getFullYear(), td.getMonth(), td.getDate()]; const dA = ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat']; const oA = [...Array.from(Array(7).keys(), idx => dA[(idx + wsd) % 7])] let dObj = {}; let midx = {}; let rObj = { cA: null, roff: null, coff: null }; oA.forEach(function (e, i) { dObj[e] = i; }); const mA = [...Array.from(new Array(12).keys(), x => Utilities.formatDate(new Date(2021, x, 15), Session.getScriptTimeZone(), "MMM"))]; mA.forEach((e, i) => { midx[i] = i; }) let cA = []; let bA = []; let wA = [null, null, null, null, null, null, null]; const year = new Date().getFullYear(); let i = midx[m % 12]; let month = new Date(year, i, 1).getMonth(); let dates = new Date(year, i + 1, 0).getDate(); cA.push([mA[month], dates, '', '', '', '', '']); bA.push(['#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff']); cA.push(oA) //bA.push(['#ffff00', '#ffff00', '#ffff00', '#ffff00', '#ffff00', '#ffff00', '#ffff00']); let d = []; let ddd = []; for (let j = 0; j < dates; j++) { let day = new Date(year, i, j + 1).getDay(); let date = new Date(year, i, j + 1).getDate(); if (day < wA.length) { wA[dObj[dA[day]]] = date; } if (cy == year && cm == month && cd == date) { rObj.roff = cA.length; rObj.coff = dObj[dA[day]]; } if (dA[day] == oA[wA.length - 1] || date == dates) { cA.push(wA); //bA.push(['#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff', '#ffffff']); wA = ['', '', '', '', '', '', '']; } } if (!ret) { rObj.cA = cA; sh.getRange(1, 1, rObj.cA.length, rObj.cA[0].length).setValues(cA); if (rObj.roff && rObj.coff) { sh.getRange(1, 1).offset(rObj.roff, rObj.coff).setFontWeight('bold').setFontColor('red'); } } else { rObj.cA = cA; return rObj; } } ``` Run the below function to create a calendar spreadsheet. Please note it will delete all other sheets. It assume January is alway the left most sheet and that there position indexes maintain the same indexes of the months in the Javascript Date() object ``` function createCalendar() { const css = SpreadsheetApp.getActive(); const months = [...Array.from(new Array(12).keys(), x => Utilities.formatDate(new Date(new Date().getFullYear(), x, 1), css.getSpreadsheetTimeZone(), "MMMM"))]; const folder = DriveApp.getFolderById(gobj.globals.testfolderid); const files = folder.getFilesByType(MimeType.GOOGLE_SHEETS); var id; var ss; while (files.hasNext()) { let file = files.next(); if (file.getName() == 'Calendar') { id = file.getId(); } } if (id) { ss = SpreadsheetApp.openById(id); } else { ss = SpreadsheetApp.create('Calendar'); let file = DriveApp.getFileById(ss.getId()); file.moveTo(folder); months.forEach(e => ss.insertSheet(e)); } ss.getSheets().filter(sh => !~months.indexOf(sh.getName())).forEach(sh => ss.deleteSheet(sh)); ss.getSheets().forEach((sh, i) => { monthlyCalendar11(i, 1, false, sh, ss); }); ``` Each sheet looks similar to this: [](https://i.stack.imgur.com/MGaS0.jpg)
null
CC BY-SA 4.0
null
2022-10-14T01:31:47.910
2022-10-14T02:20:52.673
2022-10-14T02:20:52.673
7,215,091
7,215,091
null
74,063,831
2
null
63,294,271
0
null
There is no support for regularized generalized hypergeometric functions in any module but it's straightforward to calculate regularized ones on-the-fly. Divide by the product of the gamma functions of each denominator parameter.
null
CC BY-SA 4.0
null
2022-10-14T02:53:37.723
2022-10-14T02:53:37.723
null
null
10,193,546
null
74,064,149
2
null
58,466,150
1
null
I think you have not changed your directory to where the repository is stored in your local computer. Try cd 'directory name' and then npm install
null
CC BY-SA 4.0
null
2022-10-14T03:55:14.120
2022-10-14T03:55:14.120
null
null
8,117,849
null
74,064,382
2
null
20,962,053
0
null
It depends on the versions and works with maven for me with: ``` openjdk version "17.0.4" 2022-07-19 OpenJDK Runtime Environment (build 17.0.4+8-Ubuntu-120.04) OpenJDK 64-Bit Server VM (build 17.0.4+8-Ubuntu-120.04, mixed mode, sharing) ``` mvn: ``` . . . <dependency> <groupId>org.eclipse.persistence</groupId> <artifactId>org.eclipse.persistence.moxy</artifactId> <version>3.0.1</version> </dependency> <dependency> <groupId>jakarta.json</groupId> <artifactId>jakarta.json-api</artifactId> <version>2.0.0</version> </dependency> <dependency> <groupId>org.glassfish</groupId> <artifactId>jakarta.json</artifactId> <version>2.0.1</version> </dependency> <dependency> <groupId>jakarta.json.bind</groupId> <artifactId>jakarta.json.bind-api</artifactId> <version>2.0.0</version> </dependency> . . . ``` I post this because I got the mentioned exception above with the newest versions and found no solution. Maybe this setup helps.
null
CC BY-SA 4.0
null
2022-10-14T04:39:12.517
2022-10-14T04:39:12.517
null
null
427,481
null
74,064,956
2
null
73,983,502
0
null
If you want to call third-party API from the scheduler you should pass [OAuth2AuthorizedClient](https://docs.spring.io/spring-security/site/docs/current/api/org/springframework/security/oauth2/client/OAuth2AuthorizedClient.html) to it. That class represent an OAuth2 authorized client and has information about access/refresh token. Here is the [documentation](https://docs.spring.io/spring-security/reference/reactive/oauth2/client/authorized-clients.html) describing how to use it.
null
CC BY-SA 4.0
null
2022-10-14T06:04:20.317
2022-10-14T06:04:20.317
null
null
1,268,294
null
74,065,156
2
null
74,065,002
0
null
The 2nd Column you have used should be a Row ``` body: Scaffold( body: Card( margin: EdgeInsets.all(20), shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(25)), child: Container( width: 400, height: 200, decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.circular(25.0), ), child: Padding( padding: const EdgeInsets.all(20.0), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Icon( Icons.ice_skating, size: 30, color: Colors.black, ), ], ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween,//this line is important for providing equal space crossAxisAlignment: CrossAxisAlignment.center, children: [ Text( "Hi", style: TextStyle( color: Colors.black, fontSize: 20, fontWeight: FontWeight.bold), ), SizedBox( height: 5, ), Text("spots", style: TextStyle(color: Colors.black.withOpacity(0.6))) ], ), ], ), ), ), ))), ```
null
CC BY-SA 4.0
null
2022-10-14T06:26:27.043
2022-10-14T06:26:27.043
null
null
7,487,172
null
74,065,170
2
null
74,065,002
0
null
[](https://i.stack.imgur.com/thj1X.jpg) ``` Card( margin: const EdgeInsets.all(20), shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(25)), child: Container( width: 400, height: 200, decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.circular(25.0), ), child: Padding( padding: const EdgeInsets.all(20.0), child: Column( mainAxisAlignment: MainAxisAlignment.spaceBetween, crossAxisAlignment: CrossAxisAlignment.start, children: [ const Text( 'Text', style: TextStyle(fontSize: 18), ), Row( crossAxisAlignment: CrossAxisAlignment.end, mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Text( "spots", style: TextStyle( color: Colors.black.withOpacity(0.6), ), ), const Text( "Hi", style: TextStyle( color: Colors.black, fontSize: 20, fontWeight: FontWeight.bold), ), const SizedBox( height: 5, ), const Icon( Icons.ice_skating, size: 30, color: Colors.black, ), ], ), ], ), ), ), ), ```
null
CC BY-SA 4.0
null
2022-10-14T06:28:03.223
2022-10-14T06:28:03.223
null
null
14,299,072
null
74,065,173
2
null
74,065,002
0
null
``` return Scaffold( body: Card( margin: EdgeInsets.all(20), shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(25)), child: Container( width: 400, height: 200, decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.circular(25.0), ), child: Padding( padding: const EdgeInsets.all(20.0), child: Column( crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Row( mainAxisAlignment: MainAxisAlignment.start, children: [ Text( "Hi", style: TextStyle( color: Colors.black, fontSize: 20, fontWeight: FontWeight.bold), ), ], ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Text( "Hi", style: TextStyle( color: Colors.black, fontSize: 20, fontWeight: FontWeight.bold), ), Text("spots", style: TextStyle(color: Colors.black.withOpacity(0.6))), Icon( Icons.ice_skating, size: 30, color: Colors.black, ), ], ), ], ), ), ), )); ``` [](https://i.stack.imgur.com/obSQg.png)
null
CC BY-SA 4.0
null
2022-10-14T06:28:28.243
2022-10-14T06:28:28.243
null
null
20,067,845
null
74,065,562
2
null
74,060,790
0
null
You cannot depend on a field/attribute that is modified itself. Try this: ``` /dateFormatted format(toDate(/date, "yyyyMMdd"),"yyyy-MM-dd") /day format(toDate(/date, "yyyyMMdd"),"dd") /month format(toDate(/date, "yyyyMMdd"),"MM") /year format(toDate(/date, "yyyyMMdd"),"yyyy") ``` Output: ``` { "date" : "20220103", "day" : "03", "dateFormatted" : "2022-01-03", "year" : "2022", "month" : "01" } ```
null
CC BY-SA 4.0
null
2022-10-14T07:09:46.240
2022-10-14T07:09:46.240
null
null
3,810,086
null
74,065,591
2
null
74,057,517
0
null
I reproduced this and not able to delete the records in the target using alter row. As an alternative, you can try the below approach to delete the records in database target. This is my sample : ![enter image description here](https://i.imgur.com/BDRKG8i.png) Sample : ![enter image description here](https://i.imgur.com/TuZj2Mg.png) To delete the records, you can use script in sink. For sample, here I want to delete the record with name `'Rakesh'`in sink and insert the source as it is. I have used the below script in sink Post SQL script. ``` delete from source1 where name='Rakesh' ``` ![enter image description here](https://i.imgur.com/w3zYqni.png) You can use pre script or post script as per your requirement and change the query according to your condition. `'Rakesh'` ![enter image description here](https://i.imgur.com/0deGcIw.png)
null
CC BY-SA 4.0
null
2022-10-14T07:11:45.760
2022-10-14T07:11:45.760
null
null
18,836,744
null
74,065,817
2
null
74,065,709
1
null
don't use two useEffect with the same dependency array ([]) due to this your code is executing without waiting. Instead of that combine logic of two useEffect into one also you can you async/await instead of promises syntax , it will be more readable
null
CC BY-SA 4.0
null
2022-10-14T07:33:32.613
2022-10-14T07:33:32.613
null
null
17,754,610
null
74,066,050
2
null
6,449,260
0
null
Hello Chris Can you share the codes for the same. Actually I have used grabcut algorithm to crop the face upto neck but the accuracy of images is not perfect. I am sharing the code where i am using webcam to capture images and then blurring the background and using grabcut algorithm. Please check it and reply. ``` import numpy as np import cv2 import pixellib from pixellib.tune_bg import alter_bg rect = (0,0,0,0) startPoint = False endPoint = False img_counter = 0 # function for mouse callback def on_mouse(event,x,y,flags,params): global rect,startPoint,endPoint # get mouse click if event == cv2.EVENT_LBUTTONDOWN: if startPoint == True and endPoint == True: startPoint = False endPoint = False rect = (0, 0, 0, 0) if startPoint == False: rect = (x, y, 0, 0) startPoint = True elif endPoint == False: rect = (rect[0], rect[1], x, y) endPoint = True #cap = cv2.VideoCapture("YourVideoFile.mp4") #cap = cv2.imread("/home/mongoose/Projects/background removal/bg_grabcut/GrabCut-from-video-master/IMG_6471.jpg") #capturing the camera feed, '0' denotes the first camera connected to the computer cap = cv2.VideoCapture(0) waitTime = 50 change_bg = alter_bg(model_type = "pb") change_bg.load_pascalvoc_model("/home/mongoose/Projects/background removal/bg_grabcut/test/xception_pascalvoc.pb") change_bg.blur_camera(cap, extreme = True, frames_per_second= 10, output_video_name= "output_video.mp4", show_frames= True, frame_name= "frame", detect = "person") #Reading the first frame (grabbed, frame) = cap.read() while(cap.isOpened()): (grabbed, frame) = cap.read() cv2.namedWindow('frame') cv2.setMouseCallback('frame', on_mouse) #drawing rectangle if startPoint == True and endPoint == True: cv2.rectangle(frame, (rect[0], rect[1]), (rect[2], rect[3]), (255, 0, 255), 2) if not grabbed: break cv2.imshow('frame',frame) key = cv2.waitKey(waitTime) if key == ord('q'): #esc pressed break elif key % 256 == 32: # SPACE pressed alpha = 1 # Transparency factor. img_name = "opencv_frame_{}.png".format(img_counter) imgCopy = frame.copy() img = frame mask = np.zeros(img.shape[:2], np.uint8) bgdModel = np.zeros((1, 65), np.float64) fgdModel = np.zeros((1, 65), np.float64) w = abs(rect[0]-rect[2]+10) h= abs(rect[1]-rect[3]+10) rect2 = (rect[0]+10, rect[1]+10,w ,h ) cv2.grabCut(img, mask, rect2, bgdModel, fgdModel, 100, cv2.GC_INIT_WITH_RECT) mask2 = np.where((mask == 2) | (mask == 0), 0, 1).astype('uint8') img = img * mask2[:, :, np.newaxis] cv2.imwrite(img_name, img ) print("{} written!".format(img_name)) img_counter += 1 cap.release() cv2.destroyAllWindows() ```
null
CC BY-SA 4.0
null
2022-10-14T07:54:28.550
2022-10-14T07:54:28.550
null
null
20,238,613
null
74,066,188
2
null
30,684,613
4
null
If you use compileSdkVersion 33, upgrade your Android Studio to Dolphin. It worked for me.
null
CC BY-SA 4.0
null
2022-10-14T08:06:57.663
2022-10-14T08:06:57.663
null
null
9,851,480
null
74,066,190
2
null
48,016,917
0
null
Well... I'm almost 5 years late here, but I'm adding some explanation of the answer from [@colorswall](https://stackoverflow.com/users/9823312/colorswall): In this case you're missing the type on the X-axis, this value only receives `'number'` or `'category'`. In this case you're using a date field (string) which count as a `'category'`, so you'll need to add the `allowDuplicatedCategory={false}` prop to avoid the duplicated values on that axis.
null
CC BY-SA 4.0
null
2022-10-14T08:07:08.560
2022-10-14T08:07:08.560
null
null
12,258,272
null
74,066,218
2
null
5,608,222
2
null
``` box-shadow: 0px 0px 4px 4px #000; ``` Where: - `offset-x``offset-y`- `blur radius`- `spread radius` Else, you can generate a box-shadow online, using [CSS box shadow generator](https://css-box-shadows.com/css-box-shadow-generator/)
null
CC BY-SA 4.0
null
2022-10-14T08:08:40.173
2022-10-18T23:51:18.393
2022-10-18T23:51:18.393
8,951,708
20,147,153
null
74,066,512
2
null
74,065,709
0
null
if u use useeffect with ([]) it will only work in the first load. if you want to make it work second useeffect when isLoading false, use it ([isLoading]) in that case everytime isLoading change the second useEffect will work again.
null
CC BY-SA 4.0
null
2022-10-14T08:35:03.477
2022-10-14T08:35:03.477
null
null
13,834,503
null
74,066,549
2
null
74,065,246
0
null
The `Cache` facade doesn't live in the `App\Http\Controllers` namespace. If you do not include a `use` statement at the top of your PHP files for your classes, it is assumed the `class` live in the same `namespace`. The Laravel `Cache` facade lives in the `Illuminate\Support\Facades` `namespace` so at the top of your `KakaoController` with your other `use` statements, add the following: ``` use Illuminate\Support\Facades\Cache; ```
null
CC BY-SA 4.0
null
2022-10-14T08:38:30.377
2022-10-14T08:38:30.377
null
null
281,278
null
74,066,578
2
null
23,664,510
0
null
if ur having unwanted white space in right side of ur screen its because of overflow so to remove it go to ur css then in body write ``` in css: (body{ width:100%; overflow-x: hidden; }) ``` [this is before](https://i.stack.imgur.com/GcXva.png) [this is after](https://i.stack.imgur.com/eohuO.png) this is my first help i am new to stackoverflow hope this helps
null
CC BY-SA 4.0
null
2022-10-14T08:40:38.857
2022-10-14T08:40:38.857
null
null
20,238,860
null
74,066,910
2
null
74,059,863
3
null
Your current implementation for `mouseOver/mouseOut` events is perfect. I've just found a small error - all of your yAxis labels were bold on start, so hovering on them and updating the fontWeight to bold didn't do much. Starting with manipulating the labels of the other series' axes, on `this` keyword you also have access to the chart object, which stores all of the axes. With that, you can grab the hovered series axis index (from `this.yAxis.userOptions.index`), and affect the rest of them. ``` plotOptions: { series: { events: { mouseOver: function() { const hoveredAxisIndex = this.yAxis.userOptions.index; // Update hovered axis this.yAxis.update({ labels: { style: { fontWeight: "bold" } } }); // Update the rest of axes this.chart.yAxis.forEach(axis => { if (axis.userOptions.index === hoveredAxisIndex) return; axis.update({ labels: { style: { opacity: 0.2 } } }) }); }, mouseOut: function() { // Apply the default axes styling this.chart.yAxis.forEach(axis => { axis.update({ labels: { style: { opacity: 1, fontWeight: "normal" } } }) }); } } } }, ``` When it comes to enabling the same event on legend hover, there is no built-in event like on the series, but it's fairly easy to add it by yourself on the `chart.load` event. [https://jsfiddle.net/BlackLabel/x4pcLkns/](https://jsfiddle.net/BlackLabel/x4pcLkns/) Since we use the same functions again, I would suggest a simple refactor: [https://jsfiddle.net/BlackLabel/j9pbku5h/](https://jsfiddle.net/BlackLabel/j9pbku5h/)
null
CC BY-SA 4.0
null
2022-10-14T09:07:21.953
2022-10-14T09:07:21.953
null
null
19,478,971
null
74,067,008
2
null
14,152,477
0
null
Combining Ivan's and Dale's answers I managed to achieve a result indistinguishable from the image in the assets catalog with Preserve Vector Data checkbox checked. The only downside is that the output image size is 9 times larger than the original PDF. Here is code: ``` func convertPDFDataToImage() -> UIImage? { guard let document = CGPDFDocument(url as CFURL), let page = document.page(at: 1) else { return nil } let dpi: CGFloat = 9 let pageRect = page.getBoxRect(.mediaBox) let imageSize = CGSize(width: pageRect.size.width * dpi, height: pageRect.size.height * dpi) let renderer = UIGraphicsImageRenderer(size: imageSize) let imageData = renderer.pngData { cnv in UIColor.clear.set() cnv.fill(pageRect) cnv.cgContext.interpolationQuality = .high cnv.cgContext.translateBy(x: 0.0, y: pageRect.size.height * dpi) cnv.cgContext.scaleBy(x: dpi, y: -dpi) cnv.cgContext.drawPDFPage(page) } return UIImage(data: imageData) } ```
null
CC BY-SA 4.0
null
2022-10-14T09:15:11.177
2022-10-14T09:46:49.120
2022-10-14T09:46:49.120
12,945,073
12,945,073
null
74,067,348
2
null
21,983,508
0
null
Well, I had the exact same problem, and it turned out that what was causing mine was a background change on hover effect I had set to my container. I just had to change the selector to a class selector and everything was fixed!
null
CC BY-SA 4.0
null
2022-10-14T09:41:43.053
2022-10-14T09:41:43.053
null
null
18,356,817
null
74,067,397
2
null
74,066,714
2
null
Another option is using the [geom_violinhalf](https://easystats.github.io/see/reference/geom_violinhalf.html) function from the `see` package. You could use the argument `flip` to choose the side of the half violins. Here is a reproducible example: ``` library(ggplot2) library(dplyr) library(see) df2 %>% ggplot(aes(x = variable, y = value, fill = variable)) + geom_violinhalf(flip = c(1, 3)) + geom_point() + geom_line(aes(x = variable, y = value, group = pp_code)) + scale_fill_manual(values = c("aquamarine4","aquamarine3")) + labs( title = 'Plot 1: Individual amplitude', subtitle = '10W conditions' ) + xlab("Condition")+ ylab("MEP amplitude (% baseline)")+ theme(text=element_text(family = "Helvetica Neue", size = 14), plot.title = element_text(face="bold", hjust=0), plot.subtitle = element_text(face="italic", hjust=0), axis.title.y = element_text(face="bold"), axis.title.x = element_text(face="bold"), legend.position="none", # Remove legend aspect.ratio = 1 # Make the image square ) + theme_classic() ``` ![](https://i.imgur.com/AJnVRKZ.png) [reprex v2.0.2](https://reprex.tidyverse.org)
null
CC BY-SA 4.0
null
2022-10-14T09:45:09.230
2022-10-14T09:45:09.230
null
null
14,282,714
null
74,067,417
2
null
74,067,292
0
null
use: ``` =QUERY(Houses!A:I, "select C,B,A,H where H <= "&B3&" and D = '"&B4&"' and E = '"&B5&"' and F = '"&B6&"'", 0) ``` [](https://i.stack.imgur.com/6z9vp.png) --- ## update: ``` =IFERROR(QUERY(HousingData, "select C,B,A,G where G <= "&B3& IF(B4="Y", " and D = '"&B4&"'", )& IF(B5="Y", " and E = '"&B5&"'", )& IF(B6="Y", " and F = '"&B6&"'", )& IF(B7="Y", " and J = '"&B7&"'", ), 0), "No houses found.") ``` [](https://i.stack.imgur.com/43i3B.png)
null
CC BY-SA 4.0
null
2022-10-14T09:46:48.777
2022-10-14T16:12:59.193
2022-10-14T16:12:59.193
5,632,629
5,632,629
null
74,067,621
2
null
74,067,476
0
null
That is not supposed to happen. Is it possible that you have already run a cell where `repeat_lyrics` was defined before actually calling it? Try restarting the Jupyter runtime and see if you can still do it. When you run a cell in Jupyter defining an object, you can use it across cells (provided it's in global scope), including cells that precede it.
null
CC BY-SA 4.0
null
2022-10-14T10:01:30.857
2022-10-14T10:01:30.857
null
null
11,971,720
null
74,067,638
2
null
74,067,476
0
null
The first thing that I could think of is you ran the cell earlier. From how I understand Google Colab, if you run the cell it stores that function/ 'remembers it' so if you re-run the cell it won't give an error. Same reason why running a cell that changes data can only work once. But I might be wrong. As long as your code works I wouldn't worry too much about it. You can always place the function in a new cell above the one where you call the function. I would mainly do this because it looks better.
null
CC BY-SA 4.0
null
2022-10-14T10:02:53.270
2022-10-14T10:02:53.270
null
null
20,234,296
null
74,067,721
2
null
68,546,784
1
null
New answer, JUnit 5 has been improved somewhat. If you are on Java 9+ you can use the following in `junit-platform.properties` to enable a custom parallelism. ``` cucumber.execution.parallel.enabled=true cucumber.execution.parallel.config.strategy=custom cucumber.execution.parallel.config.custom.class=com.example.MyCustomParallelStrategy ``` And you'd implement `MyCustomParallelStrategy` as: ``` package com.example; import org.junit.platform.engine.ConfigurationParameters; import org.junit.platform.engine.support.hierarchical.ParallelExecutionConfiguration; import org.junit.platform.engine.support.hierarchical.ParallelExecutionConfigurationStrategy; import java.util.concurrent.ForkJoinPool; import java.util.function.Predicate; public class MyCustomParallelStrategy implements ParallelExecutionConfiguration, ParallelExecutionConfigurationStrategy { private static final int FIXED_PARALLELISM = 4 @Override public ParallelExecutionConfiguration createConfiguration(final ConfigurationParameters configurationParameters) { return this; } @Override public Predicate<? super ForkJoinPool> getSaturatePredicate() { return (ForkJoinPool p) -> true; } @Override public int getParallelism() { return FIXED_PARALLELISM; } @Override public int getMinimumRunnable() { return FIXED_PARALLELISM; } @Override public int getMaxPoolSize() { return FIXED_PARALLELISM; } @Override public int getCorePoolSize() { return FIXED_PARALLELISM; } @Override public int getKeepAliveSeconds() { return 30; } ``` On Java 9+ this will limit the max-pool size of the underlying forkjoin pool to `FIXED_PARALLELISM` and there should never be more then 8 web drivers active at the same time. Also once [JUnit5/#3044](https://github.com/junit-team/junit5/pull/3044) is merged, released an integrated into Cucumber, you can use the `cucumber.execution.parallel.config.fixed.max-pool-size` on Java 9+ to limit the maximum number of concurrent tests.
null
CC BY-SA 4.0
null
2022-10-14T10:11:22.907
2022-10-14T10:11:22.907
null
null
3,945,473
null
74,067,791
2
null
74,043,491
0
null
I have been able to rewrite the query with some other function example as below USE Alarm DECLARE @Tag nVARCHAR(100) DECLARE db_cursor CURSOR FOR SELECT Tagname FROM OBTS_Tags OPEN db_cursor FETCH NEXT FROM db_cursor INTO @Tag DROP TABLE T1 create table T1 ( TAGNAME nVarchar(100), TIMESTAMP datetime, QUALITY VARCHAR(50), VALUE Bit ) WHILE @@FETCH_STATUS = 0 BEGIN PRINT @tag DECLARE @SQL as nVarchar(max), @Time as varchar(max), @LinkedServer varchar(100), @FSQL as nVarchar(max), @TSQL NVARCHAR(1000); ``` SET @Time = '2022-10-13 13:27' SET @LinkedServer = 'HH2' SET @SQL = 'SELECT TOP 1 * FROM OPENQUERY('+ @LinkedServer + ',''' SET @TSQL = 'select * from "!Root"."!All".RAWDATA WHERE quality = 0 and TAGNAME = '''''+@Tag+''''' AND TIMESTAMP <= '''''+@Time+''''''')'; SET @FSQL = '('+(@SQL+@TSQL)+') ORDER BY TIMESTAMP DESC' ``` PRINT @FSQL INSERT INTO T1 EXEC (@FSQL) ``` FETCH NEXT FROM db_cursor INTO @Tag ``` END CLOSE db_cursor DEALLOCATE db_cursor
null
CC BY-SA 4.0
null
2022-10-14T10:17:38.747
2022-10-14T10:17:38.747
null
null
20,223,144
null
74,067,840
2
null
74,067,468
0
null
Iam not sure what is wrong but you can use outline instead ``` .meters { display: grid; grid-template-columns: 4rem 1fr 3rem; grid-auto-rows: 1.3rem; align-items: center; gap: 0.8rem; } .meter { display: flex; height: 100%; outline: 3px solid black !important; } .fill { background: blue; } ``` ``` <div class="meters"> <p>0 Sterne</p> <div class="meter"> <div class="fill" style="width: 100%;"></div> </div> <p>27%</p> <p>1 Sterne</p> <div class="meter"> <div class="fill" style="width: 10.989%;"></div> </div> <p>11%</p> <p>2 Sterne</p> <div class="meter"> <div class="fill" style="width: 32.4176%;"></div> </div> <p>32%</p> <p>3 Sterne</p> <div class="meter"> <div class="fill" style="width: 11.5385%;"></div> </div> <p>12%</p> <p>4 Sterne</p> <div class="meter"> <div class="fill" style="width: 17.5824%;"></div> </div> <p>18%</p> </div> ```
null
CC BY-SA 4.0
null
2022-10-14T10:22:49.640
2022-10-14T10:22:49.640
null
null
19,618,315
null
74,067,977
2
null
62,325,092
0
null
When developing apps that support multiple API versions, you may want a standard way to provide newer features on earlier versions of Android or gracefully fall back to equivalent functionality. Rather than building code to handle earlier versions of the platform, you can leverage these libraries to provide that compatibility layer. In addition, the Support Libraries provide additional convenience classes and features not available in the standard Framework API for easier development and support across more devices.
null
CC BY-SA 4.0
null
2022-10-14T10:37:58.550
2022-10-14T10:37:58.550
null
null
19,423,014
null
74,068,030
2
null
74,067,942
1
null
Add line (`div`) and use `::before` and `::after` on it. ``` body { margin: 40px; background-color:#0f0e0e; font-family:Arial; } .flex { display: flex; } .flex > div:last-child { margin:10px 0 10px 15px; } .flex h1 { color:#d7d6d6; font-weight:100; margin:0; } .flex p { margin:0; color:#a6a3a5; font-size:0.9rem; font-weight:100; margin-top:10px; } .line { width: 1.5px; background: #333030; position: relative; margin-right: 10px; } .line::before { content: "<h3>"; position: absolute; color:#483f3f; top: 0; transform: translate(-43%, -100%); } .line::after { content: "</h3>"; color:#483f3f; position: absolute; bottom: 0; transform: translate(-45%, 100%); } ``` ``` <body> <div class="flex"> <div class="line"></div> <div> <h1>Simpfey</h1> <p>An Indie Web Dev.</p> </div> </div> </body> ```
null
CC BY-SA 4.0
null
2022-10-14T10:43:48.010
2022-10-15T07:56:16.767
2022-10-15T07:56:16.767
17,322,895
17,322,895
null
74,068,057
2
null
74,067,942
0
null
CSS and images ``` .main { height: 100vh; width: 100vw; display: flex; background-color: #0F0E0E; } .side { width: 125px; height: auto; min-width: 125px; background-image: url(https://i.stack.imgur.com/B6aic.png); background-repeat: no-repeat; } .content { font-family: "Bahnschrift light", "sans-serif"; font-size: 5em; color: white; padding-top: 5%; } ``` ``` <div class="main"> <div class="side"> </div> <div class="content">Simpfey</div> </div> ```
null
CC BY-SA 4.0
null
2022-10-14T10:45:42.960
2022-10-14T10:45:42.960
null
null
295,783
null
74,068,317
2
null
74,030,099
0
null
The formula in E4 can be `=IF(COUNTIF(D2:D4,0)>0,"",AVERAGE(D2:D4))` It will count the number of occurrences of zeros in last three days, if the count has some value (>0) it will show a blank and if not it will show the average of last three days
null
CC BY-SA 4.0
null
2022-10-14T11:08:50.523
2022-10-14T11:08:50.523
null
null
10,498,111
null
74,069,190
2
null
73,980,269
0
null
Your code will only update the `q_reg` output when there are events on the signals in the sensitivity list `(clk, reset)`. VHDL (and Verilog) require events to trigger changes. With signal initialization, then at time 0 the values are set, but there are no further events to simulate. Even if you did a `run 100 ns`, there would be no change in outputs since you have not had any events. Change either `clk` or `reset` some time after time 0 and try again.
null
CC BY-SA 4.0
null
2022-10-14T12:24:57.947
2022-10-14T12:24:57.947
null
null
4,367,824
null
74,069,570
2
null
25,794,256
0
null
In your dbcontext file , add : ``` protected override void OnModelCreating(DbModelBuilder modelBuilder) { Database.SetInitializer<MYDBCONTEXT>(null); base.OnModelCreating(modelBuilder); } ```
null
CC BY-SA 4.0
null
2022-10-14T12:55:25.087
2022-10-14T12:55:25.087
null
null
3,293,110
null
74,069,871
2
null
74,068,464
1
null
When passing those two arguments to the `setQuery()` method: ``` .setQuery(FirebaseDatabase.getInstance().getReference().child("Users"),model.class) ``` It means that the adapter expects to render on the screen `model` class objects. If you take a closer look at your database schema, under the "Users" node, you can see a UID (`NseK...wbv2`), and right under it, two pushed IDs. So when reading the data from the database, the Firebase-UI library tries to map each child under the above reference into an object of type `model`, which is actually not possible since the immediate children are strings and not `model` objects. To solve this you have to add a call to `.child(uid)`. So in code, it should look like this: ``` String uid = FirebaseAuth.getInstance().getCurrentUser().getUid(); DatabaseReference db = FirebaseDatabase.getInstance().getReference(); DatabaseReference uidRef = db.child("Users").child(uid); //... .setQuery(uidRef, model.class) ```
null
CC BY-SA 4.0
null
2022-10-14T13:19:53.143
2022-10-14T13:19:53.143
null
null
5,246,885
null
74,070,085
2
null
74,057,668
-1
null
``` def select(row, word): result = [] if word in row ['Color']: result.append(row['Color']) if word in row ['Clorof']: result.append(row['Clorof']) if word in row ['Diat']: result.append(row['Diat']) if word in row ['Scene']: result.append(row['Scene']) if word in row ['Ciano']: result.append(row['Ciano']) if word in row ['Ameb_Cist']: result.append(row['Ameb_Cist']) if word in row ['Vortic']: result.append(row['Vortic']) if word in row ['CiliadG']: result.append(row['CiliadG']) if word in row ['Bact_fung']: result.append(row['Bact_fung']) if word in row ['Bact_fil']: result.append(row['Bact_fil']) if word in row ['Agl_EPS']: result.append(row['Agl_EPS']) if word in row ['Microfla_ciliad']: result.append(row['Microfla_ciliad']) if word in row ['Cristais']: result.append(row['Cristais']) if len(result) > 1 and result[0] == result[1]: result = result[:1] return ",".join(result) kw= ['descolor', 'clorofitas','Diatom', 'Scene', 'Cianobact', 'Cistos', 'Vorticelas', 'Ciliados', 'fungos', 'filam', 'Aglom','Microflag', 'Cristais'] for word in kw: df[f'{word} col'] = df.apply(select, args=[word], axis=1) print(df.to_string()) ``` Your answer is really useful, is the output I need. So I applied to my data, and in the final it gave me an error "TypeError: argument of type 'float' is not iterable". Do you know how correct that?
null
CC BY-SA 4.0
null
2022-10-14T13:34:56.557
2022-10-14T13:34:56.557
null
null
20,150,135
null
74,070,182
2
null
74,070,021
0
null
You can play with widget. ``` class DialogSlider extends StatefulWidget { const DialogSlider({super.key}); @override State<DialogSlider> createState() => _DialogSliderState(); } class _DialogSliderState extends State<DialogSlider> { double? sliderValue; @override Widget build(BuildContext context) { return Scaffold( floatingActionButton: FloatingActionButton( onPressed: () async { await showDialog( context: context, builder: (context) { return StatefulBuilder( //to update ui inside dialog builder: (context, setStateSB) => AlertDialog( content: Column( mainAxisSize: MainAxisSize.min, children: [ Text("${sliderValue?.toStringAsFixed(0)}"), Row( children: [ IconButton( onPressed: () { sliderValue = (sliderValue ?? 0) - 1; if (sliderValue! < 0) { sliderValue = 0; } setStateSB(() {}); }, icon: Icon(Icons.minimize), ), Expanded( child: Slider( max: 50, value: sliderValue ?? 0, onChanged: (value) { setStateSB(() { sliderValue = value; }); }, ), ), IconButton( onPressed: () { sliderValue = (sliderValue ?? 0) + 1; setStateSB(() {}); }, icon: Icon(Icons.add), ) ], ) ], ), ), ); }, ); setState(() {}); // if we use inside body;update the UI }, ), ); } } ```
null
CC BY-SA 4.0
null
2022-10-14T13:42:32.880
2022-10-14T13:42:32.880
null
null
10,157,127
null
74,070,293
2
null
74,070,154
0
null
As Hossein Yousefi mentioned , using `Expanded` will get available space, If you to know the available size, you can use `LayoutBuilder` on top of it. ``` return LayoutBuilder( builder: (context, constraints) { return Container( height: constraints.maxHeight, ```
null
CC BY-SA 4.0
null
2022-10-14T13:50:48.233
2022-10-14T13:50:48.233
null
null
10,157,127
null
74,070,383
2
null
74,061,571
0
null
I was not exporting the route. Solving: ``` import { Router } from "express"; import { CultivationReaderController } from "../controllers/CultivationReaderController" const cultivationRoutes = Router(); const findCultivation = new CultivationReaderController(); cultivationRoutes.get("/cultivation", findCultivation.handled); export { cultivationRoutes }; ```
null
CC BY-SA 4.0
null
2022-10-14T13:57:54.730
2022-10-14T13:57:54.730
null
null
12,455,713
null
74,070,655
2
null
74,070,620
1
null
Don't use `.values` but `to_numpy(copy=True)`: ``` a = df.to_numpy(copy=True) ``` Example: ``` df = pd.DataFrame(np.zeros((3, 3), dtype=int)) a = df.to_numpy(copy=True) a[0, 0] = 999 ``` output: ``` 0 1 2 0 0 0 0 1 0 0 0 2 0 0 0 ``` Same thing with `.values`: ``` 0 1 2 0 999 0 0 1 0 0 0 2 0 0 0 ```
null
CC BY-SA 4.0
null
2022-10-14T14:19:20.330
2022-10-14T14:19:20.330
null
null
16,343,464
null
74,070,736
2
null
74,065,709
0
null
You do a `fetch` call to an API - this code is , therefore the other code won't wait for it and continue running before the data was fetched. So what you should do it take all the asynchronous code of the `fetch` and put it inside an `async` function that will return your fetched data (as a promise). Where you wrote: `setBlueCardData(dataValues)` - , so you won't immediately have the data stored in the state after writing this line. See this [link](https://www.daggala.com/react-state-not-updating-immediately/). Instead, we have he async funciton that will return the fetched `data` for us so we can use it. Second, now you can use just one `useEffect`, and inside of it you will call the async function, `data` and the promise was resolved - you'll use it, and do all the mapping you need to do. And about the `isLoading` state - all you need to do is set it to `true` in the first line of the async function - which means that now we are starting to fetch, and then in the end of the function set it to false. ``` const fetchData = async () => { setIsLoading(true); //starting to fetch. const response = await fetch('http://192.168.18.21:8000/performance/solar-overview'); const dataValues = await response.json(); setBlueCardData(dataValues); //Won't update immediately! setIsLoading(false);//finished loading.(Won't update immediately too!) return dataValues;//returning the data. }; ``` ``` useEffect(() => { fetchData().then((data) => { //This all inside the then() block - which means we finished loading and got the data. const arr3 = []; const arr4 = []; data.pr_hourly.time.map((item) => { arr4.push(item.time); }); data.pr_hourly.pr_hourly.map((item) => { arr4.push(item.pr_hourly); }); setLineData({ /* .. your code here .. */ }); }); }, []); ``` ``` if (isLoading) { return <p>Loading Data</p>; } return <div>Your data is here....</div>; } ```
null
CC BY-SA 4.0
null
2022-10-14T14:26:29.453
2022-10-16T00:51:01.087
2022-10-16T00:51:01.087
16,142,839
16,142,839
null
74,071,041
2
null
69,509,861
0
null
Just ... Restart android studio run 1. flutter clean 2. flutter pub get 3. flutter pub run flutter_launcher_icons:main 4. flutter run
null
CC BY-SA 4.0
null
2022-10-14T14:50:58.830
2022-10-14T14:52:15.273
2022-10-14T14:52:15.273
19,672,667
19,672,667
null
74,071,093
2
null
74,059,346
2
null
I think you need a dedicated plugin to do it. I have created one (it could be improve), see snippet. ``` const plugin = { id: 'myfill', beforeDatasetsDraw(chart, args, options) { const {ctx, data} = chart; ctx.save(); ctx.fillStyle = 'rgba(47, 98, 156, 0.2)'; ctx.beginPath(); let meta = chart.getDatasetMeta(0); let e = meta.data[0]; ctx.moveTo(e.x, e.y); e = meta.data[1]; ctx.lineTo(e.x, e.y); meta = chart.getDatasetMeta(1); e = meta.data[1]; ctx.lineTo(e.x, e.y); e = meta.data[0]; ctx.lineTo(e.x, e.y); ctx.fill(); ctx.restore(); } }; const ctx = document.getElementById('myChart'); const myChart = new Chart(ctx, { type: 'scatter', plugins: [plugin], data: { datasets: [{ label: 'linha 1', data:[ {x: -11, y: 7}, {x: -1, y: 8}, ], showLine: true, borderColor: 'rgb(47, 98, 156)', }, { label: 'linha 2', data: [ {x: 0, y: 7}, {x: 8, y: 8}, ], showLine: true, borderColor: 'rgb(47, 98, 156)', } ] }, options: { responsive: false, } }); ``` ``` .myChartDiv { max-width: 600px; max-height: 400px; } ``` ``` <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/chart.min.js"></script> <html> <body> <div class="myChartDiv"> <canvas id="myChart" width="600" height="400"/> </div> </body> </html> ```
null
CC BY-SA 4.0
null
2022-10-14T14:54:59.923
2022-10-14T14:54:59.923
null
null
2,057,925
null
74,071,185
2
null
58,752,965
0
null
You can also disable the setting "Markdown > Extension > TOC: Update on Save". It worked for me, I was trying to link some titles with the topic on a sumary but every time I saved the project the words with accent were automatically correcteds
null
CC BY-SA 4.0
null
2022-10-14T15:00:38.540
2022-10-14T15:00:38.540
null
null
13,688,786
null
74,071,228
2
null
3,829,841
-1
null
You can try, ``` option:disabled{ opacity: 0.6;background-color: #ff888f; } ``` ``` <select id="HouseCleaningEmp" onChange="myCalculater()"> <option value="1">option 1 </option> <option value="2">option 2 </option> <option value="3">option 3 </option> <option value="4">option 4 </option> <option value="5" disabled>option 5 </option> <option value="6" disabled>option 6 </option> <option value="7">option 7 </option> <option value="8">option 8 </option> </select> ```
null
CC BY-SA 4.0
null
2022-10-14T15:03:47.090
2022-10-14T15:03:47.090
null
null
6,249,483
null
74,071,631
2
null
27,134,077
1
null
Git repo default location and project default location are not the same thing. - -
null
CC BY-SA 4.0
null
2022-10-14T15:35:17.483
2022-10-14T15:35:17.483
null
null
20,242,333
null
74,072,009
2
null
74,065,246
0
null
You must need to add "use Illuminate\Support\Facades\Cache;" on top of controller, middleware, command, event or blade files. for example ``` <?php namespace App\Http\Controllers; use Illuminate\Support\Facades\Cache; class KaKaoController extends Controller { ... ``` or "use \Cache;"
null
CC BY-SA 4.0
null
2022-10-14T16:07:54.647
2022-10-14T16:07:54.647
null
null
20,228,579
null
74,072,068
2
null
74,069,510
0
null
Resolved! it was missing the following configuration: scales: { y: { stacked: false }, x: { stacked: true } }
null
CC BY-SA 4.0
null
2022-10-14T16:15:21.823
2022-10-14T16:15:21.823
null
null
20,240,711
null
74,072,542
2
null
74,072,484
1
null
In your variable `egress_rules` under `default` you have `[{` while it ends with `]}`. If you move `[{` to `{[` it should work.
null
CC BY-SA 4.0
null
2022-10-14T17:05:31.663
2022-10-14T17:05:31.663
null
null
6,679,867
null
74,072,551
2
null
74,066,202
0
null
Typically, numbers would be stored in the model an Integer objects and the renderer would display the number right aligned. With that in mind here is an approach that will indent both left/right aligned data by 5 pixels by adjusting the `Border` used by the renderer: ``` import java.awt.*; import java.awt.event.*; import java.util.*; import javax.swing.*; import javax.swing.table.*; import javax.swing.border.*; public class TableIndent extends JPanel { public TableIndent() { String[] columnNames = {"Date", "String", "Integer", "Boolean"}; Object[][] data = { {new Date(), "A", Integer.valueOf(1), Boolean.TRUE }, {new Date(), "B", Integer.valueOf(2), Boolean.FALSE}, {new Date(), "C", Integer.valueOf(19), Boolean.TRUE }, {new Date(), "D", Integer.valueOf(4), Boolean.FALSE} }; DefaultTableModel model = new DefaultTableModel(data, columnNames) { // Returning the Class of each column will allow different // renderers and editors to be used based on Class public Class getColumnClass(int column) { switch (column) { case 0: return Date.class; case 2: return Integer.class; case 3: return Boolean.class; } return super.getColumnClass(column); } }; JTable table = new JTable(model) { private Border insideLeft = new EmptyBorder(0, 5, 0, 0); private Border insideRight = new EmptyBorder(0, 0, 0, 5); public Component prepareRenderer(TableCellRenderer renderer, int row, int column) { Component c = super.prepareRenderer(renderer, row, column); if (renderer instanceof DefaultTableCellRenderer) { DefaultTableCellRenderer cellRenderer = (DefaultTableCellRenderer)renderer; // if ( cellRenderer.getHorizontalAlignment() == SwingConstants.LEFT ) if ( cellRenderer.getHorizontalAlignment() == SwingConstants.LEADING ) { JComponent jc = (JComponent)c; Border border = new CompoundBorder(jc.getBorder(), insideLeft); jc.setBorder( border ); } if ( cellRenderer.getHorizontalAlignment() == SwingConstants.RIGHT ) { JComponent jc = (JComponent)c; Border border = new CompoundBorder(jc.getBorder(), insideRight); jc.setBorder( border ); } } return c; } }; table.setPreferredScrollableViewportSize(table.getPreferredSize()); JScrollPane scrollPane = new JScrollPane( table ); add( scrollPane ); } private static void createAndShowGUI() { JFrame frame = new JFrame("Table Indent"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.add(new TableIndent()); frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); frame.pack(); frame.setLocationByPlatform( true ); frame.setVisible( true ); } public static void main(String[] args) throws Exception { SwingUtilities.invokeLater( () -> createAndShowGUI() ); } } ```
null
CC BY-SA 4.0
null
2022-10-14T17:06:12.483
2022-10-14T17:06:12.483
null
null
131,872
null
74,073,074
2
null
53,742,441
1
null
In Pycharm you have to reload the Python Console for sklearn to show all its components. If you do not all you see is sklearn.base and a few other general things. I just recreated this myself and found this answer.
null
CC BY-SA 4.0
null
2022-10-14T17:50:13.037
2022-10-14T17:50:13.037
null
null
3,704,338
null
74,073,156
2
null
74,068,289
0
null
I looks like you are using the same component to display different content, depending upon which tab is selected on the left. When you click on a different role, Vue will use the same component and change the props passed to this component (i.e. and ), but it won't recreate or reset the component in any way, so the data value does not get reset back to -1. When this happens, you get a new list of your subroles displayed, but it's still using the same selection/filter via , as was used when the previous tab on the left was selected. That's why you aren't seeing all the subroles under the role. The solution is to place a watch on one of the properties that change ( is good) and whenever it changes reset to -1, so all the sub-roles for the new role are displayed. ``` watch: { activeRole(oldValue, newValue) { // The activeRole has changed, so show all the jobs for this role. // This is required because this component is shared by all the roles in the sidebar. this.selectedJobId = -1 } }, ```
null
CC BY-SA 4.0
null
2022-10-14T18:00:25.267
2022-10-14T18:00:25.267
null
null
1,350,573
null
74,073,416
2
null
74,071,665
0
null
Try something like this: ``` function onMyFormSubmit(e) { Logger.log(JSON.stringify(e)); const sh = e.range.getSheet(); const osh = e.source.getSheetByName("Output Data Sheet Name") const studyId = e.namedValues["Study Id"][0]; const sampleDate = e.namedValues["Sample_date"][0]; const checkedInDate = e.namedValues["Checked_in_date"][0]; const sampleType = e.namedValues["Sample_type"][0]; const specId; let col = sh.getRange(1,1,1,sh.getLastColumn()).getDisplayValues().reduce((a,h,i) => (a[h]=i+1,a),{}); const vs = sh.getRange(2,col["StudyId"],e.range.rowStart - 1,sh.getLastColumn()).getDisplayValues().flat().filter(e => e.slice(0,6) == studyId); if(vs.length > 0) { let n = 4 - vs.length.toString().length; specId = `${studyId}/${"0".repeat(n)}${vs.length + 1}` } else { specId = `${studyId}/0001`; } let o = [[studyId,sampleDate,checkedInDate,sampleType,specId]]; osh.getRange(osh.getLastRow() + 1, 1, o.length,o[0].length).setValues(o); } ```
null
CC BY-SA 4.0
null
2022-10-14T18:28:06.660
2022-10-14T18:28:06.660
null
null
7,215,091
null
74,073,669
2
null
74,073,509
0
null
There are several ways to do this. One is to make your anchors flex containers as well, with direction 'column'. You'd then make them full height and spread their child elements with `space-between`. You could also apply flex-fill properties to the paragraph to make it expand to fill available space. See [https://css-tricks.com/snippets/css/a-guide-to-flexbox](https://css-tricks.com/snippets/css/a-guide-to-flexbox). ``` .card-container { display: flex; flex-flow: row wrap; justify-content: center; margin: auto auto 60px auto; max-width: 100vw; /* 1000px; */ } .card { background-color: #f2f2f2; width: 40%; margin: 20px; } .card a { height: 100%; display: flex; flex-direction: column; justify-content: space-between; } .card a:hover { text-decoration: none; } .card-copy { padding: 0 20px 20px 20px; } .card img { max-width: 100%; } ``` ``` <section> <h2 class="center">Apparel Design</h2> <div class="card-container"> <!--Card 1--> <div class="card"> <a href=""> <div class="card-copy"> <h3 class="margin-bottom_five">Design Process</h3> <p class="margin-top_zero">Copy here</p> </div> <img src="https://via.placeholder.com/400"> </a> </div> <!--Card 2--> <div class="card"> <a href=""> <div class="card-copy"> <h3 class="margin-bottom_five">Professional Work</h3> <p class="margin-top_zero">Copy here about my most recent professional work</p> </div> <img src="https://via.placeholder.com/400"> </a> </div> </div> </section> ```
null
CC BY-SA 4.0
null
2022-10-14T18:53:22.053
2022-10-14T18:53:22.053
null
null
1,264,804
null
74,073,663
2
null
31,155,111
0
null
might be a bit late but it still can be useful for those who struggle with alignment. Here is my complete approach: Codepen: [https://codepen.io/lakers19/pen/ZEoPpKL](https://codepen.io/lakers19/pen/ZEoPpKL) ``` const targets = [] const cleanXLine = () => { const guideLineX = document.querySelector('.guide-line-x') guideLineX.style.left = 0 guideLineX.style.top = 0 guideLineX.style.width = 0 guideLineX.style.height = 0 } const cleanYLine = () => { const guideLineY = document.querySelector('.guide-line-y') guideLineY.style.left = 0 guideLineY.style.top = 0 guideLineY.style.width = 0 guideLineY.style.height = 0 } const resetGuideLine = () => { cleanXLine() cleanYLine() } const handleStart = (event) => { // get all interactive elements targets.length = 0 const elements = document.querySelectorAll('.draggable') elements.forEach((element) => { const rect = element.getBoundingClientRect() const { x, y, width, height } = rect if (element === event.target) return const actualX = x + window.scrollX const actualY = y + window.scrollY const range = 4 targets.push({ x: actualX, range, rect, element, }) targets.push({ x: actualX + width, range, rect, element, }) targets.push({ x: actualX + width / 2, range, rect, element, }) targets.push({ y: actualY, range, rect, element, }) targets.push({ y: actualY + height, range, rect, element, }) targets.push({ y: actualY + height / 2, range, rect, element, }) }) } const drawGuideLine = (event) => { const inRange = event.modifiers.length ? event.modifiers[0]?.inRange : false if (inRange) { const guideLineX = document.querySelector('.guide-line-x') const guideLineY = document.querySelector('.guide-line-y') const { x: xModifier, y: yModifier, rect, } = event.modifiers[0].target.source const { x, y } = event.target.getBoundingClientRect() if (xModifier) { guideLineX.style.left = `${xModifier}px` guideLineX.style.top = `${Math.min(rect.y, y)}px` guideLineX.style.width = '1px' guideLineX.style.height = `${Math.abs(rect.y - y)}px` cleanYLine() } if (yModifier) { console.log(rect.x - x) guideLineY.style.left = `${Math.min(rect.x, x)}px` guideLineY.style.top = `${yModifier - window.scrollY}px` guideLineY.style.width = `${Math.abs(rect.x - x)}px` guideLineY.style.height = '1px' cleanXLine() } } else { resetGuideLine() } } interact('.draggable') .draggable({ // enable inertial throwing inertia: false, // keep the element within the area of it's parent modifiers: [interact.modifiers.snap({ targets: targets, relativePoints: [ { x: 0, y: 0 }, // snap relative to the element's top-left, { x: 0.5, y: 0.5 }, // to the center { x: 1, y: 1 }, // and to the bottom-right ], }), interact.modifiers.restrictRect({ restriction: 'parent', endOnly: true }) ], // enable autoScroll autoScroll: true, listeners: { // call this function on every dragmove event move: dragMoveListener, start: handleStart, // call this function on every dragend event end (event) { resetGuideLine() } } }) function dragMoveListener (event) { drawGuideLine(event) var target = event.target // keep the dragged position in the data-x/data-y attributes var x = (parseFloat(target.getAttribute('data-x')) || 0) + event.dx var y = (parseFloat(target.getAttribute('data-y')) || 0) + event.dy // translate the element target.style.transform = 'translate(' + x + 'px, ' + y + 'px)' // update the posiion attributes target.setAttribute('data-x', x) target.setAttribute('data-y', y) } // this function is used later in the resizing and gesture demos window.dragMoveListener = dragMoveListener ``` ``` #canvas{ width: 100vw; height: 100vh; background: rgb(22, 197, 180); } .draggable { background: rgb(71, 44, 113); width: 60px; height: 60px; } .draggable:nth-child(1){ translate: 20px 10px; } .draggable:nth-child(2){ translate: 50px 60px; } body { display: grid; place-items: center; place-content: center; height: 100%; } html{ height: 100%; } .guide-line { pointer-events:none; background:red; position:fixed; display: flex; justify-items:space-between; width: 0; height:0; left:0; right:0; } .guide-line > span { font-size: 9px; line-height: 0; color: red; position: absolute; } .guide-line-x > span { transform: translateX(-50%); left: 50%; } .guide-line-y{ flex-direction:row; } .guide-line-x { flex-direction:column; } .guide-line-y > span{ transform: translateY(-50%); top: 50%; } ``` ``` <script src="https://cdnjs.cloudflare.com/ajax/libs/interact.js/1.10.17/interact.min.js"></script> <div id="canvas"> <div class="draggable" ></div> <div class="draggable"> </div> <div class="guide-line-y guide-line"> <span style="opacity:0" >x</span> <span>x</span> </div> <div class="guide-line-x guide-line"> <span style="opacity:0">x</span> <span>x</span> </div> </div> ```
null
CC BY-SA 4.0
null
2022-10-14T18:53:14.440
2022-10-14T18:53:14.440
null
null
10,330,468
null
74,073,988
2
null
71,473,114
0
null
You forgot to add the `text` attribute to `go.Bar` plot, which should contain the same value of y-axis. ``` import pandas as pd import plotly.express as px import plotly.graph_objects as go CG = pd.read_csv("CoverageGroups.csv", header=0) fig = go.Figure() fig.add_trace(go.Bar(name='Employment Based', x=CG.Group, y=CG['Employment Based'], marker_color='silver',text=CG['Employment Based'])) fig.add_trace(go.Bar(name='Medicaid', x=CG.Group, y=CG['Medicaid'], marker_color='grey', text=CG['Medicaid'])) fig.add_trace(go.Bar(name='Other', x=CG.Group, y=CG['Other'], marker_color='silver', text=CG['Other'])), fig.update_layout(barmode='stack') fig.update_traces(textposition = 'inside') fig.show() ``` [](https://i.stack.imgur.com/JiBrC.png)
null
CC BY-SA 4.0
null
2022-10-14T19:25:05.617
2022-10-14T19:25:05.617
null
null
16,733,101
null
74,074,191
2
null
68,435,021
0
null
On Above answers, The Stepper on Vertical axis will cause the stepper line to shrink to centre. So to avoid that. You should use Row. Also if you want to Avoid space caused by this change, use margin: EdgeInsets.zero, ``` margin: EdgeInsets.zero, controlsBuilder: (context, controller) => Row(children: []); ```
null
CC BY-SA 4.0
null
2022-10-14T19:47:13.080
2022-10-14T19:47:13.080
null
null
12,748,499
null
74,074,414
2
null
74,073,409
0
null
delete everything in your C3:C range and use this in C3: ``` =INDEX(IF(A3:A="";;IF(B3:B>64; INT(B3:B/64)&" pack(s) e "& IF(B3:B=(INT(B3:B/64))*64; 0; B3:B-((INT(B3:B/64)*64))); "-"))) ``` [](https://i.stack.imgur.com/zLOo7.png)
null
CC BY-SA 4.0
null
2022-10-14T20:11:41.160
2022-10-14T20:11:41.160
null
null
5,632,629
null
74,074,561
2
null
74,074,273
0
null
You should find what your looking for on [this page](https://woocommerce.com/document/free-shipping/) of woocommerce documentation
null
CC BY-SA 4.0
null
2022-10-14T20:29:53.320
2022-10-14T20:29:53.320
null
null
19,140,003
null
74,074,957
2
null
72,433,536
0
null
You need to pass in a PAT as well in your request. this page shows you how to create a PAT if you have not already: [https://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops&tabs=Linux](https://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops&tabs=Linux) This page shows how you can pass in your PAT in your request using postman: [Azure Devops 203 Non-Authoritative Information with REST API](https://stackoverflow.com/questions/58991603/azure-devops-203-non-authoritative-information-with-rest-api)
null
CC BY-SA 4.0
null
2022-10-14T21:18:30.373
2022-10-14T21:18:30.373
null
null
8,088,414
null
74,075,026
2
null
74,072,534
2
null
If you have binary outcome data and a numeric predictor, the typical way to model this would be with logistic regression. You can show a logistic regression quite easily in ggplot by passing `method = glm` and `method.args = list(family = binomial))` to `geom_smooth`. You can augment this by adding the successes and failures as a sort of "rug plot", and adding a few aesthetic tweaks: ``` ggplot(test, aes(V1, V2)) + geom_point(shape = "|", size = 6, na.rm = TRUE, aes(color = factor(V2))) + geom_smooth(method = glm, method.args = list(family = binomial), na.rm = TRUE, formula = y ~ x, color = "navy", fill = "lightblue") + coord_cartesian(ylim = c(0, 1), expand = 0) + labs(x = "Age", y = "Probability") + theme_minimal(base_size = 16) + theme(axis.line = element_line(color = "gray"), axis.ticks = element_line(color = "gray"), axis.ticks.length = unit(3, "mm"), legend.position = "none") ``` [](https://i.stack.imgur.com/5YSO5.png) Note that this is preferable to a plain loess because with a loess (or other methods that do not explicitly account for the binary nature of the data) will give inaccurate confidence intervals (your target plot has a confidence interval which goes above 100% probability, which clearly doesn't make sense).
null
CC BY-SA 4.0
null
2022-10-14T21:27:31.383
2022-10-14T21:27:31.383
null
null
12,500,315
null
74,075,609
2
null
74,075,520
0
null
Increase the number shown in the picture below [](https://i.stack.imgur.com/FNMda.png)
null
CC BY-SA 4.0
null
2022-10-14T23:18:03.913
2022-10-14T23:18:03.913
null
null
13,755,144
null
74,075,869
2
null
74,075,674
1
null
you could try this approach: ``` List { ForEach(networkManager.breweries) { brewery in // All the list items that will get loaded in } }.blendMode(networkManager.breweries.isEmpty ? .destinationOver : .normal) ```
null
CC BY-SA 4.0
null
2022-10-15T00:26:45.093
2022-10-15T00:51:31.217
2022-10-15T00:51:31.217
11,969,817
11,969,817
null
74,075,987
2
null
74,072,385
1
null
If I've understood your requirements correctly, all you need to do is to add `height: 0` to `#application_container`. ``` * { box-sizing: border-box; position: relative; } html, body { height: 100%; width: 100%; padding: 0; margin: 0; display: flex; flex-direction: column; overflow: clip; } header, div { border-width: 6px; border-style: solid; text-align: center; overflow: clip; } header, #content, #footer { padding: 1em; } header { border-color: #090; background-color: #0c0; color: #030; flex: none; } #application_container { border-color: #c90; background-color: #fc0; color: #330; flex: auto; display: flex; flex-direction: row; height: 0; } #sidebar { border-color: #ccc; background-color: #fff; color: #999; flex: none; width: 150px; } #workbench_container { border-color: #f3f; background-color: #f6f; color: #939; flex: auto; display: flex; flex-direction: column; overflow: clip auto; } #content_container { border-color: #36c; background-color: #69f; color: #039; flex: 1 0 auto; } #content { border-color: #900; background-color: #c00; color: #300; } #content.small { min-height: 150px; } #content.large { min-height: 1500px; } #footer { border-color: #999; background-color: #ccc; color: #333; flex: none; } ``` ``` <!DOCTYPR html> <html lang=""> <head> <title>Flex Box Test</title> <head> <body> <header>The header shall always be visible at the top</header> <div id="application_container"> <div id="sidebar">This is the sidebar</div> <div id="workbench_container"> <div id="content_container"> <!-- Toggle the class between "small" and "large" to see the (failing) effect --> <div id="content" class="large"> This is the real content whose size is unknown in advance. Hence, it is wrapped into a content container which is at least as large as the actual content, but can grow such that the footer is at the bottom. </div> </div> <div id="footer"> For small content the footer shall be located at the bottom. But for large content the footer shall be placed at the end of the content and be scrolled as part of the (pink) workbench container. </div> </div> </div> </body> </html> ``` Whether or not this is a Firefox bug is harder. What Firefox is doing is taking the height of the containing block only if it has a definite size, and is using the height value to decide that, even though it's growing under the flex rules.
null
CC BY-SA 4.0
null
2022-10-15T01:04:46.180
2022-10-15T01:04:46.180
null
null
42,585
null
74,076,230
2
null
74,076,159
0
null
In `handleExpandItem` add `e.stopPropagation()`. That way the event will not "bubble up" (propagate) to the parent event handler.
null
CC BY-SA 4.0
null
2022-10-15T02:16:48.347
2022-10-15T02:16:48.347
null
null
26,742
null
74,076,328
2
null
74,076,159
4
null
Welcome to this community! I'm new too, so I'll try to do my best to answer your question: What's happening is that when you're clicking `<div className="accordion1" onClick={(e) => handleExpandItem(e)}></div>` You're also clicking `<div className="ContainerTitle1" onClick={() => handleAddComponent()}></div>` Because it is his parent, so both get clicked, but your accordion gets firstly fired since it is the closer one to your screen (capturing phase), then their parents get clicked too (it's like your click event getting propagated to the parents) and their event handlers get fired in consequence. So, what you are looking for is to prevent the event from propagating from the event target (which is the closest element to your screen) to the parent's event handlers, and you can do so by using `event.stopPropagation()` inside your `handleExpandItem(e)` handler, e.g ``` function handleExpandItem(e){ e.stopPropagation(); //Some other stuff you want to do } ``` Here's an article about this issue: [https://www.freecodecamp.org/news/event-propagation-event-bubbling-event-catching-beginners-guide/](https://www.freecodecamp.org/news/event-propagation-event-bubbling-event-catching-beginners-guide/) Hope it helps!
null
CC BY-SA 4.0
null
2022-10-15T02:43:56.637
2022-10-15T02:50:43.147
2022-10-15T02:50:43.147
20,134,350
20,134,350
null
74,076,987
2
null
68,348,596
0
null
``` Include these import statements in your view-name.ts file import '@vaadin/icon'; import '@vaadin/vaadin-lumo-styles/vaadin-iconset.js'; import '@vaadin/icons'; ```
null
CC BY-SA 4.0
null
2022-10-15T05:41:35.633
2022-10-15T05:41:35.633
null
null
8,813,362
null
74,077,289
2
null
10,647,389
0
null
## you can bring the values to desired html object as well `var place = autocomplete.getPlace(); $('#latitude').val(place.geometry['location'].lat()); $('#longitude').val(place.geometry['location'].lng());`
null
CC BY-SA 4.0
null
2022-10-15T06:46:32.310
2022-10-15T06:46:32.310
null
null
10,499,323
null
74,077,473
2
null
9,332,003
0
null
Just in case you have this issue on the app start, note that [bundle pathForResource] will not work earlier than in the applicationDidFinishLaunching. Update: Also, make sure you are running it from the main thread.
null
CC BY-SA 4.0
null
2022-10-15T07:17:01.827
2022-10-18T14:23:57.813
2022-10-18T14:23:57.813
1,123,662
1,123,662
null
74,077,528
2
null
53,285,132
0
null
I think Outlook Object Model does not provide any mechanism to do this. Maybe you can do it using a kind of hack using Windows API functions or hooks. AFAIK The title bar (header), buttons and borders of the custom task pane are managed and drawn by Outlook VSTO itslef. In fact the custom task pane is a borderless window but VSTO adds the rest (borders, title bar - header -, buttons).
null
CC BY-SA 4.0
null
2022-10-15T07:27:20.397
2022-10-15T07:27:20.397
null
null
1,624,552
null
74,077,715
2
null
51,424,578
1
null
The problem I had was that my YouTube video was stuck loading when I embedded it. But if I logged out from my YouTube account, then it started to work. I hope this is a temporary bug YouTube will fix soon.
null
CC BY-SA 4.0
null
2022-10-15T07:58:39.683
2022-10-15T07:58:39.683
null
null
2,104,665
null
74,077,748
2
null
74,077,685
0
null
You just have to set the `flex-grow` property of the child elements to `0` instead of `1` ``` .video-container { background-color: blue; min-height: 90vh; display: flex; flex-wrap: wrap; } .video { flex: 0 0 25%; } ``` ``` <div class="video-container"> <video class="video" style="background: red;"></video> <video class="video" style="background: blue;"></video> <video class="video" style="background: yellow;"></video> <video class="video" style="background: green;"></video> <video class="video" style="background: orange;"></video> <video class="video" style="background: red;"></video> </div> ```
null
CC BY-SA 4.0
null
2022-10-15T08:03:39.067
2022-10-15T08:03:39.067
null
null
17,235,431
null
74,077,837
2
null
74,077,697
1
null
Just wrap that sepcific ordered list with with nested `dt` elements with a pandoc div `:::` and define a css class (`.dtList`) and define all the css rules specifically for this class which would only affect those ordered lists that has the class `.dtList`. ``` --- author: CLRR date: | | Last Update: `r format(Sys.time(), '%Y/%m/%d')`) output: revealjs::revealjs_presentation: self_contained: false reveal_plugins: ["notes", "search"] transition: slide pandoc_args: - --wrap=preserve --- # Ordered list where definition lists are nested ::: {.dtList} 1. Item A ~ This is A! ~ It's good! 1. Item B ~ This is B! ~ It's new! ::: # Ordered list but the numbers disappear 1. Item Alpha 1. Item Bravo 1. Item Charlie ```{css, echo=FALSE} .reveal .dtList li { list-style-type: none; } .reveal .dtList ol { counter-reset: css-counter 0; } .reveal .dtList li dt { counter-increment: css-counter 1; } .reveal .dtList li dt:before { content: counter(css-counter) ". "; width: 1rem; } .reveal .dtList li dd { margin-left: 2em; } .reveal h1, .reveal h2, .reveal h3, .reveal h4, .reveal h5, .reveal h6 { font-family: 'Roboto', 'Noto Sans JP', sans-serif; } .reveal h1, .reveal h2 { font-family: 'Roboto', 'Noto Sans JP', sans-serif; font-weight: bold; } .reveal code{ font-family: 'Roboto Mono', monospace; /* margin: 2px 2px; padding: 0 5px; white-space: nowrap; border: 1px solid #eaeaea; background-color: #6E6E6E; border-radius: 3px; font-size: 24pt; */ } .reveal pre { font-family: 'Roboto Mono', monospace; /* background-color: #6E6E6E; border: 1px solid #cccccc; font-size: 24pt; line-height: ; overflow: auto; padding: 0; border-radius: 3px; */ } .reveal pre code { font-family: 'Roboto Mono', monospace; /* white-space: pre; background-color: transparent; border: none; */ } .reveal .slide { font-family: 'Roboto', 'Noto Sans JP', sans-serif; } /* 12pt |name | pt| relative_size| |:-------------|-----:|-------------:| |\tiny | 6.00| 50.00000| |\scriptsize | 8.00| 66.66667| |\footnotesize | 10.00| 83.33333| |\small | 10.95| 91.25000| |\normalsize | 12.00| 100.00000| |\large | 14.40| 120.00000| |\Large | 17.28| 144.00000| |\LARGE | 20.74| 172.83333| |\huge | 24.88| 207.33333| |\Huge | 24.88| 207.33333| */ .reveal .footer { font-size: 83%; } .columns { display: flex !important; justify-content: center; align-items: center; } .column { display: inline-block; /* word-break: break-all; */ /* display: inline-flex; */ /* flex: auto; */ } .uri { word-break: break-all; } .reveal .speaker-controls { font-family: 'Roboto', 'Noto Sans JP', sans-serif; } /* #vcenter { vertical-align: middle; } */ ``` <style> @import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@100;300;400;500;700;900&family=Roboto+Mono:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap'); </style> ``` --- [](https://postimg.cc/LgkpGwmX) [](https://postimg.cc/1fPPDmKN) ---
null
CC BY-SA 4.0
null
2022-10-15T08:18:45.897
2022-10-15T08:35:18.890
2022-10-15T08:35:18.890
10,858,321
10,858,321
null
74,077,907
2
null
74,076,248
0
null
You can use `v-on:click` for getting event correctly when using vue ``` <div v-on:click="clickWallet">Click me</div> ```
null
CC BY-SA 4.0
null
2022-10-15T08:30:59.000
2022-10-15T08:30:59.000
null
null
19,514,458
null
74,078,469
2
null
74,075,054
0
null
Your code having a `ThreadLocal<Yaml>` implies you're writing from multiple threads. You'll need to properly [lock the target file](https://www.baeldung.com/java-lock-files) for that. This is not guaranteed to be the answer; I see no other obvious flaws in your code though.
null
CC BY-SA 4.0
null
2022-10-15T09:59:41.533
2022-10-15T09:59:41.533
null
null
347,964
null
74,078,538
2
null
74,069,959
2
null
Given that the noise is nearly exclusively black and white (i.e. desaturated) whereas the fish is colour, I would convert to [HSV colourspace](https://en.wikipedia.org/wiki/HSL_and_HSV) and look to the Saturation channel for providing separation - the middle one in the row below: [](https://i.stack.imgur.com/HjxgW.jpg)
null
CC BY-SA 4.0
null
2022-10-15T10:10:39.820
2022-10-21T13:43:22.933
2022-10-21T13:43:22.933
2,836,621
2,836,621
null
74,078,612
2
null
74,066,327
2
null
# In short You could show the relationship between the template `Base` and the template `Derived` either with a parameter binding (like in your picture, but between two template classes) or inheritance between template classes. But neither alternative is completely accurate regarding the C++ and the UML semantics at the same time. For this you would need to decompose the template inheritance into a binding and an inheritance. # More explanations ## What does your C++ code mean? The C++ generalization between `Derived` and `Base` makes three things at once: - `Base``TD1``TB1``TD2``TB2``int``TB3`- `TD1``TD2`- For the readers who are less familiar with C++, let's illustrate this by using aliases to clarify: ``` template<typename TB1, typename TB2, typename TB3> class Base { }; template<typename TD1, typename TD2> class Derived : public Base<TD1, TD2, int> { }; int main() { using MyDerived = Derived<string, Test>; // class corresponding to binding parameters using MyBase = Base<string, Test, int>; // also binding parameters MyBase *p = new MyDerived(); // this assignment works because the bound // MyBase generalization is a generalization // from MyDerived } ``` So this code means that there is a generic specialization of `Base` into `Derived` which is true, whatever the parameter bindings, and in particular for the bound `MyBase` and `MyDerived`. ## How to show it in UML? ### Option 1 - binding A first possibility is to simply use `<<bind>>` between template classes: > : (...) the details of how the contents are merged into a bound element are left open. (...) A bound Classifier may have contents in addition to those resulting from its bindings. `Derived` would be a bound classifier obtained by binding parameters of `Base` and adding "own content", including redefinitions of base elements ("overrides"). This is not wrong, but would not appropriately reflect that there is an inheritance also between bound classes obtained from `Derived` and bound classes obtained directly from `Base`. ## Option 2 - inheritance Another approach could be inheritance between the templates: [](https://i.stack.imgur.com/zfLz8.png) It corresponds to the C++ semantics. But the UML section gives another semantic to this diagram: > A RedefinableTemplateSignature redefines the RedefinableTemplateSignatures of all parent Classifiers that are templates. All the formal TemplateParameters of the extended (redefined) signatures are included as formal TemplateParameters of the extending signature, along with any TemplateParameters locally specified for the extending signature. I understand this as meaning that the template parameters increase (i.e. the set would be `TB1`, `TB2`, `TB3`, `TD1` and `TD2`) and there is no semantics nor notation foreseen to define a local binding of some parents elements. So UML readers might misunderstand the design intent. ## Option 3 - binding and inheritance The cleanest way would therefore be to decompose the binding and the inheritance (I've used a bound class that is itself templated with the new parameter name to align, but this could be overkill) : [](https://i.stack.imgur.com/4Jtjk.png)
null
CC BY-SA 4.0
null
2022-10-15T10:25:02.853
2022-10-15T15:16:48.623
2022-10-15T15:16:48.623
3,379,653
3,723,423
null
74,079,648
2
null
74,079,622
1
null
``` name value A 34 B 25 A 18 C 14 B 16 A 9 B 4 C 9 name value A 61 B 45 C 23 ``` A: ``` SELECT name, SUM(value) FROM tableName GROUP BY name ```
null
CC BY-SA 4.0
null
2022-10-15T12:55:48.067
2022-10-15T13:07:41.897
2022-10-15T13:07:41.897
8,404,453
20,248,718
null
74,079,668
2
null
74,079,622
0
null
use: ``` =QUERY(V:X; "select V,sum(W),sum(X) where V is not null group by V") ```
null
CC BY-SA 4.0
null
2022-10-15T12:58:28.053
2022-10-15T12:58:28.053
null
null
5,632,629
null
74,080,056
2
null
64,237,442
2
null
Better to use `LazyVerticalStaggeredGrid` Follow this steps > Step 1 Add the below dependency in your `build.gradle` file ``` implementation "androidx.compose.foundation:foundation:1.3.0-rc01" ``` > Step 2 import the below classes in your activity file ``` import androidx.compose.foundation.lazy.staggeredgrid.LazyVerticalStaggeredGrid import androidx.compose.foundation.lazy.staggeredgrid.StaggeredGridCells ``` > Step 3 Add `LazyVerticalStaggeredGrid` like this ``` LazyVerticalStaggeredGrid( columns = StaggeredGridCells.Fixed(2), state = state, modifier = Modifier.fillMaxSize(), content = { val list = listOf(1,2,4,3,5,6,8,8,9) items(list.size) { position -> Box( Modifier.padding(5.dp) ) { // create your own layout here NotesItem(list[position]) } } }) ``` OUTPUT [](https://i.stack.imgur.com/49WNy.png)
null
CC BY-SA 4.0
null
2022-10-15T13:56:15.637
2022-10-15T13:56:15.637
null
null
7,666,442
null
74,080,165
2
null
74,079,971
0
null
That's not a warning (definitely not in the Python sense). This just means Pycharm's introspection can't find definitions for that module. This in turn is because it's a compiled module (OpenCV is a C++ project with wrappers for Python) so the "usual" Python source files (for introspection) isn't an option. For a much deeper discussion and some recent workarounds, see the Github issue on [adding Python typing stubs to OpenCV](https://github.com/opencv/opencv/issues/14590).
null
CC BY-SA 4.0
null
2022-10-15T14:10:52.363
2022-10-15T14:10:52.363
null
null
604,382
null
74,080,274
2
null
74,071,991
0
null
Create three new cells and split up the `AND` arguments to the 3 cells. See what is false and what should be true to pinpoint the error.
null
CC BY-SA 4.0
null
2022-10-15T14:25:12.160
2022-10-15T14:25:12.160
null
null
8,404,453
null
74,080,652
2
null
17,251,016
0
null
Hi I was looking for this answer too, found it after like 80 minutes searching, Only work, to activate DWMWA_USE_IMMERSIVE_DARK_MODE found it here: [Can I change the title bar in Tkinter?](https://stackoverflow.com/questions/23836000/can-i-change-the-title-bar-in-tkinter) I didnt found dwmwindowattribute in dwmwindowattribute that affect Top bar color sadly :(. It should be possible to call DWMWA_BORDER_COLOR, but honestly I dont know how, there is some article calling it in C++ here: [change-the-color-of-the-title-bar-caption-of-a-win32-application](https://stackoverflow.com/questions/39261826/change-the-color-of-the-title-bar-caption-of-a-win32-application) Tried this but doesnt work: `set_window_attribute(hwnd, 22, '0x000000FF', 4)` Here is working code for : ``` import tkinter as tk import ctypes as ct def dark_title_bar(window): """ MORE INFO: https://learn.microsoft.com/en-us/windows/win32/api/dwmapi/ne-dwmapi-dwmwindowattribute """ window.update() set_window_attribute = ct.windll.dwmapi.DwmSetWindowAttribute get_parent = ct.windll.user32.GetParent hwnd = get_parent(window.winfo_id()) value = 2 value = ct.c_int(value) set_window_attribute(hwnd, 20, ct.byref(value), 4) root = tk.Tk() root.title("Crystaly Ball") root.geometry("1400x900") root.configure(background="#222246") dark_title_bar(root) root.mainloop() ```
null
CC BY-SA 4.0
null
2022-10-15T15:14:40.427
2022-10-17T05:51:05.113
2022-10-17T05:51:05.113
15,416,118
15,416,118
null
74,080,764
2
null
74,076,140
4
null
I just had this same issue (see my comment above). What worked for me was to go into "Edit Configurations", delete the configuration that was copied over from the original PC, and create my own configuration (basically with the same inputs as before).
null
CC BY-SA 4.0
null
2022-10-15T15:31:58.673
2022-10-15T15:31:58.673
null
null
5,403,987
null