components

How can I troubleshoot design-time packages in Delphi/C++Builder?

為{幸葍}努か 提交于 2021-02-07 20:56:15
问题 I have consistently had IDE problems in Delphi/C++Builder for years, with every version. I usually just reboot, recompile, etc. and move on. However, I keep seeing others say that the IDE is rock solid. I've read many people say that most IDE problems are a result of custom component problems. We have several of our own custom components and I would not be at all surprised that they were causing the problems. However, I have no idea how to find out. 1) I cannot easily just uninstall a

How to pass optional elements to a component as a prop in reactjs

时光怂恿深爱的人放手 提交于 2021-02-07 11:54:06
问题 I am trying to figure out the proper "react" way to pass in an optional prop that is an Element to a container component, that is handled differently from the children of that component. For a simple example, I have a Panel component, which renders its children, that also has an optional "title" prop (which is an element rather than a string, for the sake of the example) that gets specially rendered (put in a special spot, with special behaviors in while maintaining the abstraction. One

How to use service method inside a component?

﹥>﹥吖頭↗ 提交于 2021-02-04 21:42:09
问题 I am not able to use the service method inside a component. I have a service and a component. Component import { Component, OnInit } from '@angular/core'; import { Customer, Userdetails} from "./usermaster.model"; import { UsermasterService } from './usermaster.service'; @Component({ selector: 'ngx-usermaster', templateUrl: './usermaster.component.html', styleUrls: ['./usermaster.component.scss'], providers: [ UsermasterService ] }) export class UsermasterComponent implements OnInit { values:

How to configure project with COMPONENTS in cmake

烂漫一生 提交于 2021-02-04 14:01:47
问题 I want to create a project of projects using cmake which is accessible in a similar manner to that used by Poco. I find that using Poco as an example is crowded and difficult to follow so I am trying to create a minimal version, without macros so that I can see what is going on. I have constructed a repository for this example here. https://github.com/markeastwood82/nomnoms This, and what is written below is currently my best guess at how to solve this problem after some days of reading up /

How can I have single Vue component and how each contents in that can be routed by buttons of other component

主宰稳场 提交于 2021-01-29 22:41:23
问题 I am new to Vuejs, I am looking to make my code effective just by having one vue component, and i want to specify the routing only once. Currently i have one info.vue in a apps directive and prises.vue & priseshigh.vue in more directive. I want to have just one component in more directive. But the problem is in info.vue i have used two buttons, each button routes to prises.vue & priseshigh.vue respectively. Just like below code: <vs-button class="btn" @click="$router.push({name: 'prises'})

React Typescript Class Component Default Props Interface

旧时模样 提交于 2021-01-29 20:29:07
问题 I created a simple class component with some props. Since Typescript 3 and above, they state that defaultProps by default will use the same Interface as the component's props itself. reference In the following code example, you can see I created a component, extending React.PureComponent with a given interface. One prop is called boolean with type boolean. Then I got the static defaultProps assignment where I made an "accidental" typo where I put a string instead of a boolean. import React

Expand one card on click

谁都会走 提交于 2021-01-29 18:13:13
问题 Currently using Material-UI-React for the first time to build out cards that expand, the issue I'm running into is when I click on one card to expand, they all expand.How can I refactor my code to only allow the card that is clicked on to expand not affecting the others? const useStyles = makeStyles(theme => ({ card: { maxWidth: 300 }, media: { height: 0, paddingTop: '56.25%' // 16:9 }, expand: { transform: 'rotate(0deg)', marginLeft: 'auto', transition: theme.transitions.create('transform',

Vue.js component parent event

好久不见. 提交于 2021-01-29 10:36:34
问题 im wondering why my code isn't working. I have an event 'leave' which should be called on blur. The components are displayed properly but when i leave the inputs the event wont be triggered. Vue.component('text-input', { props:['args'], template: '<input :id="args.id" :type="args.type"/>' }) App = new Vue({ el : '#app', data: { inputs : [ { id : 'nickname', type : 'text'}, { id : 'email' , type:'email'}, ] }, methods : { leave : function(event) { var id = $(event.target).attr('id'); console

Spring @PreAuthorize hasAuthority Exception Failed to convert from type [java.lang.String] to type [java.lang.Boolean] for value 'hasAuthority

泪湿孤枕 提交于 2021-01-29 09:50:36
问题 So I created a class with two simple public strings public final class Right { private Right() { super(); } public static final String AUTH = "hasAuthority('admin') or hasAuthority('mod')"; } When I used it together with the @PreAuthorize annotation at my controllers it works like a charm. I do not like that it is hardcoded. For this reason I've put the roles in the properties and I tried to use it as a component: @Component("authRule") public class AuthRule { @Value("${role.administrator}")

Reload component with vue-router

三世轮回 提交于 2021-01-29 09:40:20
问题 I have a project with Vuejs and Vue-Router. When a user pay in (login) system, the server return a file Json with token, username and first name, this file is stored in localstorage for be used in following requests. The first name is used in layout for show a message welcome in the navbar. After logout, localstorage is cleared and the problem is here, when other user pay in the message welcome not reload with new first name. <v-chip>{{bienvenida}}</v-chip> computed: { bienvenida() { const