Firebase Ui auth version 3.2.2 xml errors - firebase

I am trying to connect a firebaseUI auth but I keep getting an error with an unknown xml file
Here is my build gradle files:
apply plugin: 'com.android.application'
repositories {
mavenLocal()
flatDir {
dirs 'libs'
}
}
android {
compileSdkVersion 24
buildToolsVersion '26.0.2'
defaultConfig {
applicationId "com.google.firebase.udacity.friendlychat"
minSdkVersion 16
targetSdkVersion 24
versionCode 1
versionName "1.0"
resConfigs "auto"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE-FIREBASE.txt'
exclude 'META-INF/NOTICE'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'junit:junit:4.12'
compile 'com.android.support:design:24.2.0'
compile 'com.android.support:appcompat-v7:24.2.0'
// Displaying images
compile 'com.github.bumptech.glide:glide:3.6.1'
compile 'com.google.firebase:firebase-database:11.8.0'
compile 'com.google.firebase:firebase-auth:11.8.0'
compile 'com.firebaseui:firebase-ui-auth:3.2.2'
}
apply plugin: 'com.google.gms.google-services'
and here is the xml file which appears:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Base.Theme.AppCompat" parent="Base.V26.Theme.AppCompat"/>
<style name="Base.Theme.AppCompat.Light" parent="Base.V26.Theme.AppCompat.Light"/>
<style name="Base.V26.Theme.AppCompat" parent="Base.V23.Theme.AppCompat">
<!-- We can use the platform styles on API 26+ -->
<item name="colorError">?android:attr/colorError</item>
</style>
<style name="Base.V26.Theme.AppCompat.Light" parent="Base.V23.Theme.AppCompat.Light">
<!-- We can use the platform styles on API 26+ -->
<item name="colorError">?android:attr/colorError</item>
</style>
<style name="Base.V26.Widget.AppCompat.Toolbar" parent="Base.V7.Widget.AppCompat.Toolbar">
<item name="android:touchscreenBlocksFocus">true</item>
<item name="android:keyboardNavigationCluster">true</item>
</style>
<style name="Base.Widget.AppCompat.Toolbar" parent="Base.V26.Widget.AppCompat.Toolbar"/>
</resources>
Here are the errors which appear from this:
[:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar]
Error:(252, 5) error: resource android:attr/keyboardNavigationCluster not found.
Error:(252, 5) error: resource android:attr/fontStyle not found.
Error:(252, 5) error: resource android:attr/font not found.
Error:(252, 5) error: resource android:attr/fontWeight not found.
C:\and-nd-firebase-1.00-starting-point\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values-v26\values-v26.xml
Error:(36) error: style attribute 'android:attr/autofillHints' not found.
Error:(7) resource android:attr/colorError not found.
Error:(11) resource android:attr/colorError not found.
Error:(15) style attribute 'android:attr/keyboardNavigationCluster' not found.
Error:(18) style attribute 'android:attr/keyboardNavigationCluster' not found.
Error:(24) style attribute 'android:attr/autofillHints' not found.
Error:(28) style attribute 'android:attr/autofillHints' not found.
Error:(32) style attribute 'android:attr/autofillHints' not found.
Error:(36) style attribute 'android:attr/autofillHints' not found.
C:\and-nd-firebase-1.00-starting-point\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml
Error:(250) resource android:attr/keyboardNavigationCluster not found.
Error:(468) resource android:attr/fontStyle not found.
Error:(468) resource android:attr/font not found.
details
Error:Execution failed for task ':app:processDebugResources'.
Failed to execute aapt
Information:BUILD FAILED in 8s
Information:29 errors
Information:0 warnings
Information:See complete output in console
Any help would be much appreciated.

Use version 27.0.2 of the Support libraries:
compile 'com.android.support:design:27.0.2'
compile 'com.android.support:appcompat-v7:27.0.2'
And change:
compileSdkVersion 27 // was 24
You may also want to use the latest version of Glide:
compile 'com.github.bumptech.glide:glide:4.3.1'

Related

Warning: Built-in CSS support is being disabled due to custom CSS configuration being detected

I am trying to import "../../node_modules/react-quill/dist/quill.snow.css"; in my next.js project but I get following error
[ error ] ./node_modules/react-quill/dist/quill.snow.css
Global CSS cannot be imported from files other than your Custom <App>. Please move all global CSS imports to pages/_app.js.
Read more: https://err.sh/next.js/css-global
Location: components\crud\BlogCreate.js
I managed to make it work with next.config.js. It worked with this configuration
// next.config.js
const withCSS = require('#zeit/next-css');
module.exports = withCSS({
cssLoaderOptions: {
url: false
}
});
But now I am getting a warning,
Warning: Built-in CSS support is being disabled due to custom CSS configuration being detected.
See here for more info: https://err.sh/next.js/built-in-css-disabled
It seems my solution is not the best way to solve this problem. How could I get rid of this warning?
You may remove the #zeit/next-css plugin because the Next.js 9.3 is very simple. Then Next.js 9.3 is Built-in Sass Support for Global Stylesheets after removing the #zeit/next-css you may install
npm install sass
Then, import the Sass file within pages/_app.js.
Global CSS
Import any global CSS in the /pages/_app.js.
import '../styles.css'
// This default export is required in a new `pages/_app.js` file.
export default function MyApp({ Component, pageProps }) {
return <Component {...pageProps} />
}
Importing CSS in components or pages won't work with the built-in CSS support.
Component CSS
Next.js supports CSS Modules using the [name].module.css file naming convention.
components/Button.module.css
/*
You do not need to worry about .error {} colliding with any other `.css` or
`.module.css` files!
*/
.error {
color: white;
background-color: red;
}
components/Button.js
import styles from './Button.module.css'
export function Button() {
return (
<button
type="button"
// Note how the "error" class is accessed as a property on the imported
// `styles` object.
className={styles.error}
>
Destroy
</button>
)
}
CSS Module files can be imported anywhere in your application.
Third-party CSS on Component / Page level
You can use <link> tag in the component.
const Foo = () => (
<div>
<link
href="third.party.css"
rel="stylesheet"
/>
</div>
);
export default Foo;
The loaded stylesheet won't be automatically minified as it doesn't go through build process, so use the minified version.
If none of the options doesn't fit your requirements consider using a custom CSS loader like #zeit/next-css.
In that case you will see a warning which is fine:
Warning: Built-in CSS support is being disabled due to custom CSS configuration being detected.
See here for more info: https://err.sh/next.js/built-in-css-disabled
Suggested reading:
Next.js Built-In CSS Support
Global SASS
CSS Modules
Install sass module by running following command.
npm install sass
You then need to remove all css-loader and sass-loader configuration from next.config.js.
For example, I had to remove the withSass() function (in your case withCSS()) and just return the configuration object.
Had to remove the following lines from next.config.js
{
test: /\.scss$/,
use: {
loader: "sass-loader",
options: {
data: '#import "./scss/_variables.scss"',
sourceMap: true,
},
},
}
Move your options to sassOptions in next config file.
sassOptions: {
data: '#import "./scss/_variables.scss"',
sourceMap: true,
}
Also remove the old #zeit/next-sass and #zeit/next-css from package.json
I had to remove following #zeit dependency from my package.json
"dependencies": {
"#zeit/next-sass": "1.0.1",
This worked for me.
For more details, visit https://nextjs.org/docs/basic-features/built-in-css-support

com.google.android.material.R Cannot resolve symbol 'R' for BottomNavigationView

I use BottomNavigationView in my App, but I have a problem: in BottomNavigationView.java there is import com.google.android.material.R and R is red and write "Cannot resolve symbol 'R'".
The topics I saw couldn't help me.
What would you recommend for me?
The dependencies:
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
defaultConfig {
applicationId "com.example.yourspeakingclub"
minSdkVersion 24
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
sourceSets {
main {
java.srcDirs = ['src/main/java', 'src/main/java/Models', 'src/main/java/com/salendor/yourspeakingclub/models']
}
}
buildToolsVersion = '28.0.3'
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'com.android.support:support-compat'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta2'
implementation 'com.google.android.gms:play-services-maps:17.0.0'
testImplementation 'junit:junit:4.13-beta-3'
androidTestImplementation 'androidx.test:runner:1.3.0-alpha02'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0-alpha02'
implementation 'com.google.android.material:material:1.1.0-beta01'
}
The layout:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="#+id/navigation_container_id"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingTop="?android:attr/actionBarSize">
<com.google.android.material.bottomnavigation.BottomNavigationView
android:id="#+id/navigation_element"
android:layout_width="wrap_content"
android:layout_height="56dp"
android:layout_gravity="start"
android:background="?android:attr/windowBackground"
app:itemTextColor="#000000"
app:labelVisibilityMode="unlabeled"
app:itemIconTint="#color/colorBlack"
app:menu="#menu/bottom_menu" />
</FrameLayout>
The class definition where is the problem with 'R' is available here: https://github.com/material-components/material-components-android/blob/master/lib/java/com/google/android/material/bottomnavigation/BottomNavigationView.java
Thanks
I experienced this problem when I updated Gradle to the latest version. When I returned to version 3.1.3 the error simply disappeared
change this in your build.graddle (project)
classpath 'com.android.tools.build:gradle:3.1.3'
The error should be resolved by doing Alt+Enter & adding the right import. But I'm guessing this issue came out of nowhere after you had already built & run the project at least once (as it once happened with me).
This could be because you're unable to reference the elements of the XML layout. In this case, try:
Build -> Clean project
.
This resolved my issue. Hopefully, it'll help you too :)
I had the same problem.
Simply updated this tool in build.graddle (project) file
classpath 'com.android.tools.build:gradle:4.1.0'
and it worked !!

Build springboot for cordapp - javax.Json not found exception

I am writing a springboot to integrate with cordaapp and building with gradle. I want to call CordaRPC in springboot. Though i am able to build i am getting this below error always,
java.lang.ClassNotFoundException: javax.json.JsonValue
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at net.corda.nodeapi.ArtemisTcpTransport$Companion.tcpTransport(ArtemisTcpTransport.kt:84)
at net.corda.nodeapi.ArtemisTcpTransport$Companion.tcpTransport$default(ArtemisTcpTransport.kt:44)
at net.corda.client.rpc.CordaRPCClient.<init>(CordaRPCClient.kt:108)
at net.corda.client.rpc.CordaRPCClient.<init>(CordaRPCClient.kt:83)
at net.corda.client.rpc.CordaRPCClient.<init>(CordaRPCClient.kt:83)
at net.corda.client.rpc.CordaRPCClient.<init>(CordaRPCClient.kt)
for the line,
CordaRPCClient rpcClient = new CordaRPCClient(rpcAddress);
Snippet of my build.gradle file,
... apply plugin: 'java' apply plugin: 'org.springframework.boot' apply plugin: 'io.spring.dependency-management' apply plugin: 'net.corda.plugins.cordapp' apply plugin: 'net.corda.plugins.cordformation' apply plugin: 'net.corda.plugins.quasar-utils' ... dependencies {
testCompile "junit:junit:$junit_version"
// Corda integration dependencies
cordaCompile "$corda_release_group:corda-core:$corda_release_version"
cordaCompile "$corda_release_group:corda-finance:$corda_release_version"
cordaCompile "$corda_release_group:corda-jackson:$corda_release_version"
cordaCompile "$corda_release_group:corda-rpc:$corda_release_version"
cordaCompile "$corda_release_group:corda-webserver-impl:$corda_release_version"
cordaRuntime "$corda_release_group:corda:$corda_release_version"
cordaRuntime "$corda_release_group:corda-webserver:$corda_release_version"
testCompile "$corda_release_group:corda-node-driver:$corda_release_version"
// CorDapp dependencies
// Specify your cordapp's dependencies below, including dependent CorDapps
cordapp "$corda_release_group:corda-finance:$corda_release_version"
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.11.0'
compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.11.0'
compile group: 'org.apache.logging.log4j', name: 'log4j-slf4j-impl', version: '2.11.0'
// implementation 'org.springframework.boot:spring-boot-starter-data-jpa' // implementation 'org.springframework.boot:spring-boot-starter-jersey'
implementation ('org.springframework.boot:spring-boot-starter-web', {
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-logging'
exclude group: 'org.springframework.boot', module: 'logback-classic'
}
)
testImplementation 'org.springframework.boot:spring-boot-starter-test'
implementation files('<path to my cordapp jar>')
} ...
Add the dependency
group='javax.json', module='javax.json-api', version='1.1.4'
The actual issue is apply plugin: 'io.spring.dependency-management'.
This is bumping org.apache.activemq:artemis-core-client from 2.6.2 to 2.6.4 which is where the org.apache.geronimo.specs:geronimo-json_1.0_spec:1.0-alpha-1 goes missing.
If you remove the spring plugin everything will work again.
Despite what is generated by Spring Initializr, you only need
apply plugin: 'java'
apply plugin: 'org.springframework.boot'
and you can safely remove apply plugin: 'io.spring.dependency-management'

Postcss-extend. 'class not found' when file is #imported from node_modules folder?

Hello I'm getting an error where the extend module can't find a class contained within an imported file located in the 'node_modules' directory.
Error message
error in ./resources/assets/pcss/app.pcss
Module build failed: ModuleBuildError: Module build failed:
#extend .relative; // fails
^
".footer" failed to #extend ".relative".
The selector ".relative" was not found.
app.pcss file
#import '../../../node_modules/basscss-position/index.css'; /* contains .relative */
/* #import 'basscss-position/index.css'; this also fails */
#import "./test.pcss"; /* contains .bg-primary */
.footer {
#extend .bg-primary; /* works */
#extend .relative; /* fails */
}
webpack.mix.js
let mix = require('laravel-mix'); // aka webpack wrapper that makes things simple
let convertLength = require('convert-css-length');
let convert = convertLength('13px');
mix.sass('resources/assets/pcss/app.pcss', 'public/css')
.options({
postCss: [
require('postcss-import')(),
require('postcss-cssnext')({ browsers: ['last 2 versions', 'ie >= 9']}),
require('postcss-extend')()
]
})
Add to script object in package.json
script: {
"watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --
progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
"production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
}
I've noticed that if I change the node_module file from .css to .pcss then it will work but I'm not sure why and I don't really want to do this.
I've faced similar issue in the past, the thing is this is not a bug of postcss-extend, you should report this bug in postcss-import or simply you can replace your postcss-import dependency with postcss-simple-import which is far better and managed properly by developers.

grunt uncss cannot seem to set the css path

I have setup a uncss grunt task.
my html files are in the 'public' folder
my css ares in 'public/css'.
I setup my grunt task like so:
uncss: {
dist: {
files: {
'faq.min.css' : ['public/faq.html']
}
}
}
I get an error saying:
Fatal error: UnCSS: could not open /css
I do import my css like so in my html page:
<link href="css/faq.min.css" rel="stylesheet" />
I've tried setting up htmlroot, csspath, but nothing seems to work.
if I set
csspath: 'css'
it adds an extra css to the path.
/homepage/public/css/css/faq.min.css
anyone can help?

Resources