interaction design – Subsequent editing of inline “click to enter text” fields

I’m iterating on a SaaS platform where there is a notes functionality on certain elements which are shared between all users of the platform.

Currently, it’s handled via the notes section starting out with a “Click to enter text” empty state.

Clicking note text is also the only way to launch into editing once a user has written a note.

While the means of editing that field may be clear for the first user who see’s the empty state, I worry that losing that signifier could hurt visibility for subsequent users reading the note who may want to edit.

I plan on examining this (among other things) to a certain extent in some user tests/interviews, but I’d appreciate insight any of you may have as well!

enter image description here

database design – Fields for storing user passwords

What coulmn heads would you need, generally speaking, for storing user passwords in a database, and what would be their datatypes be (irrespective of specific encryption algorithm used)?

One VARCHAR(x) for encrypted password and another for the salt?

views – How to get drupal fields and customize themes

I’m trying to customize a durpal theme, but I’m getting tired to guess the path of getting different fields of data types. for example, here are some few examples:

row.content('#row')._entity.title.value (for titles)
row.content('#row')._entity.field_image.entity.uri.value (for images)
row.content('#row')._entity.field_image(0).alt (for images alt)
row.content('#row')._entity.body.summary (for summaries)

How can I get my taxonomies labels, and is their any effective way to debug and get he nodes & elements structure

openldap corrupting some dn fields

Any idea why openldap would start corrupting some dns ?

lidf export shows

dn:: Y249Q8OpY2lsZSBCRU5BWkVULG91PWtja191c2VycyxkYz1tY2RwazEsZGM9Z2FtLGRjPWN

(line break included)

apparently it doesn’t want to show a version number

# /usr/sbin/slapd -VV
@(#) $OpenLDAP: slapd  (Feb  9 2019 17:02:42) $
        Debian OpenLDAP Maintainers <>

hooks – After webform submission restrict/greyout certain fields when user goes back in to edit

On my Drupal 7 instance I am letting anonymous users “edit own webform content” or “access own webform results.” The thing is, I want one or two of the fields to become un-editable after the initial submission. Once they click through the link in their confirmation email to edit their submission, I want the email and company name fields to be greyed out but all other fields to be editable. What is my path of least resistance?

unity – How to create a re-usable layout of text fields that can be bound to in world space?

Current tools:

  • Unity 2020.3.2f1 (Win10)
  • UI Builder preview package

My end-goal is to do the following:

  1. At varying intervals, change values for many data objects in the background, such as prices, resources, demand, supply, etc.
  2. Display those values in a flat table/list (as they change) in world space to the player, e.g. on a TV screen (or a transparent panel hovering above it, etc.)
  3. Have the ability to apply that layout (and its bindings) to another world space object of a different size, e.g. on a smaller or wider TV screen

Imagine an office with 15 desks, all with 3 monitors showing the same data feeds and changing statistics, except the monitors were all different shapes and sizes. How could you avoid building all 45 monitor layouts individually, and binding to each field separately? So my question is:

What is the “right” way to build a re-usable UI (ideally with UXML/USS), display it in world space, and have the ability to update the text in that layout?

I thought that UI Builder + UXML/USS would be the answer, but I am having trouble parsing how my end goal would be accomplished using that (or if that is even an appropriate use case for UI Builder). Fields that are displayed using UIDocuments are not exposed in the Hierarchy, and can’t be dragged onto a script’s input in the Inspector, for example. I’m able to project a UXML/USS layout onto a texture => material => object, but I’m not sure how to bind to the fields within the layout:

Panel Test

The screenshot above is my latest attempt, a POC of a live timer (on the right) manually being updated (using a TextMeshPro field, works great), and the yellow panel to the left is a UXML/USS layout pasted onto a texture/material that’s applied to a panel (in a canvas). On the far left is that same layout being used as a HUD, just to confirm it works the same as the floating panel. In-game, this data will not be part of the HUD, it will only be in world space. As a POC, I have been trying unsuccessfully to get the timer value from the gray panel to bind to the “should be time” text in the UXML.

So, should I just bite the bullet and build each layout by hand using game objects (such as in the gray panel)? Or am I halfway there with the UXML and just misunderstanding how UIDocuments work? Or is there a new smarter way of doing this I haven’t heard of yet? Not looking for a full code example or anything, just a push in the right direction.

configuration – How can I merge a content type’s fields and settings from dev to staging?

I have an existing content type on staging. On dev we’ve added a ton of new fields and display and form setting changes, etc.

It’s not practical to go through the config files and find all of the many dozens if not hundreds of interconnected config files related to the content types, its fields and its settings.

So I heard Features is the way to go (even though I thought config sync in D8 was supposed to make Features not needed anymore).

So I’ve created my Feature. Keeping it simple I just checked the single content type. Saved my feature module and moved it to staging.

When I try to enable to the module I get a screen full of “unable to install” because the configuration already exists errors. Ugg.

So I read that I should remove the configurations. But this removes content and/or associated configurations like vocabularies.

Surely there must be a practical way to merge a content type from dev to staging?

python – Como usar com varios Fields no com imagem (SOCORRO)

Estou tentando fazer uma regra que permite usar todos os meus fields que estão no arquivo aparecerem na def, nem precisar colar varias linhas fields.. Isso nao é tão simples por que eu tenho um if que trata salvamento de imagem e categoria no formulario que esta no “addphoto” tambem. ( no codigo abaixo voces vão ver ).
eu ja tentei criar uma “” e não tive sucesso. Sera que alguem pode me ajudar ?

from django.db import models

class Category(models.Model):
    Essa categoria eu fiz separado para trabalhar com get pk.
    name = models.CharField(max_length=100, null=False, blank=False)
    def __str__(self):

class Photo(models.Model):
    #Campos do formulario
    category = models.ForeignKey(Category, on_delete=models.SET_NULL, null=True, blank=True)
    image = models.ImageField(null=False, blank=False)
    titulo=models.CharField(max_length=150, blank=True)
    description = models.TextField(max_length=300, blank=True)

    class Meta():
        verbose_name = 'Photo'
        verbose_name_plural = 'Photos'

            from django.shortcuts import render, redirect
            from .models import Category, Photo
            # Configurações da galeria e tela inicial
            def gallery(request):
                category = request.GET.get('category')
                if category == None:
                    photos = Photo.objects.all()
                    photos = Photo.objects.filter(category__name=category)
                categories = Category.objects.all()
                context = {'categories': categories, 'photos': photos}
                return render(request, 'photos/gallery.html', context)
            # Configuração para ver a foto quando clica no botão
            def viewPhoto(request, pk):
                photo = Photo.objects.get(id=pk)
                return render(request, 'photos/photo.html', {'photo': photo})
            # tela do formulario onde adiciona as fotos e fields
            def addPhoto(request):
                categories = Category.objects.all()
                #Pegar a foto
                if request.method == 'POST':
                    data = request.POST
                    image = request.FILES.get('images')
                    #se for selecionada a categocia criada pela o id da category criada. senão cria uma nova na hora do form.
                    if data('category') != 'none':
                        category = Category.objects.get(id=data('category'))
                    elif data('category_new') != '':
                        category, created = Category.objects.get_or_create(
                        category = None
                    #Aqui nao consegui modificar. Ele cria um objeto com categoria, imagem e coloquei um field pra testar. desse jeito funciona so que eu teria q adicionar 25 fields ai. 
                    photo = Photo.objects.create(
                        # Exemplo 
                        # nome, titulo, data, ..... 25 vezes 
                    return redirect('gallery')
                context = {'categories': categories}
                return render(request, 'photos/add.html', context)

    from django.forms import ModelForm
    from .models import Photo
    class TransformPhoto(ModelForm):
        class Meta():
            model = Photo
            fields = '__all__'

Nesse codigo eu reduzi as Fields que estão no é pra ser 25 campos.
eu queria colocar esses campos no na parte “addphoto”. Esse Addphoto é um formulario onde eu preencho algumas informações e pesquiso uma imagem. E essas informações e imagem são cadastradas.

qualquer duvida manda mensagem. ! Obrigada.

javascript – provide module, main and browser fields that satisfy esm, commonjs and bundlers

I have a number of published npm packages that I have upgraded to provide both commonjs and esm builds. Some of the packages might be for both node and the browser. All packages compiled with webpack or rollup. All are written in typescript and transpiled into a dist directory.

I create a commonjs index.js file that looks like this:

 'use strict'
  if (process.env.NODE_ENV === 'production') {
    module.exports = require('./react-abortable-fetch.cjs.production.min.js')
  } else {
    module.exports = require('./react-abortable-fetch.cjs.development.js')

I set the package.json main field to the above index.js file.

I also generate a .esm.js file for each package and I set both browser and module fields to the esm.js file and set the type file to be module.

The end result is something like this:

  "type": "module",
  "main": "dist/index.js",
  "browser": "dist/react-abortable-fetch.esm.js",
  "module": "dist/react-abortable-fetch.esm.js",
  "types": "dist/index.d.ts",

The problem with this approach is that only esm packages can consume it (unless I am wrong).

What is the best way to configure the package.json file so that packages that have not made the leap yet (and that is quite a few) can still consume the package?

When serializing a class, can its fields take their defaults from the Unity editor?

Can I have a custom serialized class whereby I set a value in the editor and that value persists into runtime, as happens with serialized monobehaviour fields?

Currently it sets itself to 0 or a default hard coded from within the class.

I noticed that using a struct actually works but using a struct breaks the events used in my actual use case (included below).

Example code:

public class Class1 : MonoBehaviour
    // this variable can be set in the editor and persist into run time
    private float testVar1;

    // this variable can not
    private Class2 class2;

    private void Start()
        class2 = new Class2();

public class Class2
    private float testVar2;

My use case:

public class EditorFloat
    public float value; 
    public EventProperty<float> eventProperty;

    public EditorFloat(EventProperty<float> eventProperty)

        this.eventProperty = eventProperty;
        Object.FindObjectOfType<CentralParams>().OnUiChange += Update;
        this.eventProperty.OnChanged += UpdateEditor;
    public void Update()
        eventProperty.Value = value;
    public void UpdateEditor(float valueFromEventProperty)
        value = valueFromEventProperty;